[go: up one dir, main page]

CN112589232B - A welding seam tracking method and device based on independent rectification deep learning - Google Patents

A welding seam tracking method and device based on independent rectification deep learning Download PDF

Info

Publication number
CN112589232B
CN112589232B CN202011477237.0A CN202011477237A CN112589232B CN 112589232 B CN112589232 B CN 112589232B CN 202011477237 A CN202011477237 A CN 202011477237A CN 112589232 B CN112589232 B CN 112589232B
Authority
CN
China
Prior art keywords
welding
weld
welding seam
guide rail
tracking
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202011477237.0A
Other languages
Chinese (zh)
Other versions
CN112589232A (en
Inventor
高向东
杜健准
张艳喜
梁添汾
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Guangdong University of Technology
Original Assignee
Guangdong University of Technology
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Guangdong University of Technology filed Critical Guangdong University of Technology
Priority to CN202011477237.0A priority Critical patent/CN112589232B/en
Publication of CN112589232A publication Critical patent/CN112589232A/en
Application granted granted Critical
Publication of CN112589232B publication Critical patent/CN112589232B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • BPERFORMING OPERATIONS; TRANSPORTING
    • B23MACHINE TOOLS; METAL-WORKING NOT OTHERWISE PROVIDED FOR
    • B23KSOLDERING OR UNSOLDERING; WELDING; CLADDING OR PLATING BY SOLDERING OR WELDING; CUTTING BY APPLYING HEAT LOCALLY, e.g. FLAME CUTTING; WORKING BY LASER BEAM
    • B23K9/00Arc welding or cutting
    • B23K9/12Automatic feeding or moving of electrodes or work for spot or seam welding or cutting
    • B23K9/127Means for tracking lines during arc welding or cutting
    • BPERFORMING OPERATIONS; TRANSPORTING
    • B23MACHINE TOOLS; METAL-WORKING NOT OTHERWISE PROVIDED FOR
    • B23KSOLDERING OR UNSOLDERING; WELDING; CLADDING OR PLATING BY SOLDERING OR WELDING; CUTTING BY APPLYING HEAT LOCALLY, e.g. FLAME CUTTING; WORKING BY LASER BEAM
    • B23K9/00Arc welding or cutting
    • B23K9/12Automatic feeding or moving of electrodes or work for spot or seam welding or cutting
    • B23K9/127Means for tracking lines during arc welding or cutting
    • B23K9/1272Geometry oriented, e.g. beam optical trading
    • B23K9/1274Using non-contact, optical means, e.g. laser means
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02PCLIMATE CHANGE MITIGATION TECHNOLOGIES IN THE PRODUCTION OR PROCESSING OF GOODS
    • Y02P90/00Enabling technologies with a potential contribution to greenhouse gas [GHG] emissions mitigation
    • Y02P90/30Computing systems specially adapted for manufacturing

Landscapes

  • Physics & Mathematics (AREA)
  • Engineering & Computer Science (AREA)
  • Plasma & Fusion (AREA)
  • Mechanical Engineering (AREA)
  • Optics & Photonics (AREA)
  • Geometry (AREA)
  • Length Measuring Devices By Optical Means (AREA)

Abstract

本发明涉及一种基于独立纠偏型深度学习的焊缝跟踪方法及装置,所述装置包括:工作平台、控制器、竖直方向导轨、水平方向导轨、焊枪夹具、线结构光视觉传感器、伺服电机;所述方法包括:S1:采集焊缝结构光图片;S2:读取焊缝结构光图片;S3:利用YOLOV3识别到当前焊缝类型并定位焊缝中心位置;S4:以S3定位的焊缝中心位置作为跟踪目标,并初始化KCF跟踪器;S5:焊接开始,利用KCF‑YOLOV3算法实时跟踪焊缝;直至焊接结束。本发明所述焊接装置及焊接方法能够自动识别多种焊缝并精确定位焊缝中心区域,可有效提高焊缝检测速度以及识别准确率,从而提高焊接效率。

Figure 202011477237

The invention relates to a welding seam tracking method and device based on independent rectification type deep learning. The device comprises: a working platform, a controller, a vertical guide rail, a horizontal guide rail, a welding torch fixture, a line structured light vision sensor, and a servo motor ; The method includes: S1: collecting the structured light picture of the welding seam; S2: reading the structured light picture of the welding seam; S3: identifying the current welding seam type by using YOLOV3 and locating the center position of the welding seam; S4: positioning the welding seam with S3 The center position is used as the tracking target, and the KCF tracker is initialized; S5: The welding starts, and the KCF‑YOLOV3 algorithm is used to track the welding seam in real time; until the welding ends. The welding device and the welding method of the invention can automatically identify various welding seams and accurately locate the central area of the welding seam, which can effectively improve the welding seam detection speed and recognition accuracy, thereby improving the welding efficiency.

Figure 202011477237

Description

一种基于独立纠偏型深度学习的焊缝跟踪方法及装置A welding seam tracking method and device based on independent rectification type deep learning

技术领域technical field

本发明涉及焊接技术领域,更具体地,涉及一种基于独立纠偏型深度学习的焊缝跟踪方法及装置。The invention relates to the technical field of welding, and more particularly, to a welding seam tracking method and device based on independent deviation correction type deep learning.

背景技术Background technique

基于结构光视觉的焊缝跟踪技术结合了计算机视觉和激光三维测量技术的优点,具有数据信息采集简单、焊缝特征明显、抗干扰能力强等优良特性,因激光具有良好的方向性、单色性、相干性和能力集中等优点,从而广泛应用于结构光的光源。目前,线结构光视觉传感下的焊缝跟踪已经比较成熟。为了减少焊接过程中强烈弧光的干扰,通常会在摄像机镜头前安装一定带宽的滤光镜片,以保持获得清晰的结构光图像,通过信号采集和图像处理得到焊缝中心位置。The welding seam tracking technology based on structured light vision combines the advantages of computer vision and laser 3D measurement technology, and has excellent characteristics such as simple data information collection, obvious welding seam characteristics, and strong anti-interference ability. It has the advantages of stability, coherence and ability concentration, so it is widely used in the light source of structured light. At present, the welding seam tracking under the line structured light vision sensing is relatively mature. In order to reduce the interference of strong arc light in the welding process, a filter lens with a certain bandwidth is usually installed in front of the camera lens to keep a clear structured light image, and the center position of the weld is obtained through signal acquisition and image processing.

目前焊缝跟踪的解决方案基本上是焊接设备与跟踪装置一体化,这种技术方案的缺点在于需要在跟踪装置与焊接设备之间制定复杂的通信协议,需要考虑传感信号和控制信号的传输问题,软件编写难度大,产品开发周期长,且只能应用于特定的工业场景。The current solution for welding seam tracking is basically the integration of welding equipment and tracking device. The disadvantage of this technical solution is that a complex communication protocol needs to be formulated between the tracking device and the welding equipment, and the transmission of sensing signals and control signals needs to be considered. The problem is that the software is difficult to write, the product development cycle is long, and it can only be applied to specific industrial scenarios.

现有基于视觉传感的焊缝跟踪系统基本由计算机与视觉传感器组成,在上位机软件中,计算机实时显示视觉传感器采集的图像,并通过特定的图像处理算法获取焊缝中心位置,然后计算焊缝偏差,最终发出控制命令。计算机虽然性能强大,但其缺点也不容忽视:体积大,占用空间多,不适合在某些工业现场应用;成本高,性价比不高;安装不灵活、不方便。所以计算机并不适合在作业现场大规模的工业化应用。The existing welding seam tracking system based on visual sensing is basically composed of a computer and a visual sensor. In the host computer software, the computer displays the image collected by the visual sensor in real time, and obtains the center position of the welding seam through a specific image processing algorithm, and then calculates the welding seam. seam deviation, and finally issue a control command. Although the performance of the computer is powerful, its shortcomings cannot be ignored: it is large in size and occupies a lot of space, which is not suitable for application in some industrial fields; the cost is high, and the cost performance is not high; the installation is inflexible and inconvenient. Therefore, the computer is not suitable for large-scale industrial application on the job site.

在焊接生产过程中,根据坡口形式和连接方式的不同,焊缝类型主要有以下几种:平板对接型焊缝、搭接焊缝、V型焊缝、角接焊缝、环形焊缝。每种焊缝类型的结构光条纹图像各不相同,因此需要根据焊缝类型开发特定的图像特征提取算法,同时在机器人自动焊接中亦要根据焊缝类型调整焊接速度、焊接电流和电压等参数。然而,传统的焊缝跟踪系统需要在焊接前手动输入焊缝类型,从而严重降低了焊接机器人的自动化水平。随着计算机硬件性能的显著提升和数据样本的大量增加,以卷积神经网络(convolutional neuralnetworks,CNN)为基础的深度网络开始成为目标检测技术的主流。目前,基于深度学习的目标检测技术能同时做到实时性的目标分类和目标定位,在准确度和抗干扰程度上都取得较好的效果。将这种技术运用于焊缝跟踪,能实现焊接前的焊缝类型识别和焊缝中心定位、焊接时的实时焊缝检测和持续修正跟踪结果。In the welding production process, according to the different groove forms and connection methods, there are mainly the following types of welds: flat butt welds, lap welds, V-shaped welds, fillet welds, and annular welds. The structured light fringe image of each type of weld is different, so it is necessary to develop a specific image feature extraction algorithm according to the type of weld, and at the same time, parameters such as welding speed, welding current and voltage should also be adjusted according to the type of weld in automatic robot welding. . However, conventional seam tracking systems require manual input of the seam type before welding, which severely reduces the automation level of the welding robot. With the significant improvement of computer hardware performance and the large increase of data samples, deep networks based on convolutional neural networks (CNN) have become the mainstream of object detection technology. At present, the target detection technology based on deep learning can simultaneously achieve real-time target classification and target positioning, and achieve good results in terms of accuracy and anti-interference. Applying this technology to weld seam tracking can realize weld type identification and weld center positioning before welding, real-time weld detection during welding, and continuous correction of the tracking results.

近年来,目标跟踪算法开始应用于焊缝跟踪,国内外许多学者围绕基于目标跟踪算法的焊缝跟踪进行了深入研究。目标跟踪算法分别分为生成式模型和判别式模型两大类,生成式模型通过建立模型来描述跟踪目标特性,代表算法有光流法、卡尔曼滤波等,然而焊缝跟踪系统模型生成难度大,一般在工程上难以实现;判别式模型在跟踪过程中引入在线学习的分类器,包含目标的正样本与包含背景的负样本构成了样本集,这类算法跟踪性能良好,代表算法有TLD、KCF、深度学习类方法。其中,KCF算法运用相关滤波技术,在跟踪准确度与鲁棒性能上均具有良好的表现,适用于焊缝跟踪。KCF算法的缺点在于长时间跟踪时容易积累跟踪误差以及噪声干扰导致模型漂移,在跟踪过程中存在弧光、散射激光、金属飞溅等噪声,严重影响KCF算法跟踪焊缝中心,从而降低焊缝跟踪精度。In recent years, target tracking algorithm has been applied to weld seam tracking, and many scholars at home and abroad have conducted in-depth research on weld seam tracking based on target tracking algorithm. The target tracking algorithm is divided into two categories: generative model and discriminative model. The generative model describes the characteristics of the tracking target by establishing a model, and the representative algorithms include optical flow method, Kalman filter, etc. However, it is difficult to generate the model of the weld tracking system. , which is generally difficult to achieve in engineering; the discriminant model introduces an online learning classifier in the tracking process, and the positive samples containing the target and the negative samples containing the background constitute a sample set. This kind of algorithm has good tracking performance, and the representative algorithms include TLD, KCF, deep learning methods. Among them, the KCF algorithm uses the relevant filtering technology, which has good performance in tracking accuracy and robust performance, and is suitable for welding seam tracking. The disadvantage of the KCF algorithm is that it is easy to accumulate tracking errors and noise interference during long-term tracking, which leads to model drift. In the tracking process, there are noises such as arc light, scattered laser light, and metal spatter, which seriously affect the KCF algorithm to track the center of the weld, thereby reducing the accuracy of the weld tracking. .

目前,国内外的焊缝跟踪系统大多都是基于传统PC的机器视觉系统,其主要包括计算机、视觉传感系统、图像采集卡、运动控制卡等,其缺点是体积大,占用空间多,不利于应用于某些条件苛刻的工业环境;成本高昂,能耗大,性价比不高;安装难度大,不易于调试。此外,传统焊缝跟踪系统需要与焊接设备制定复杂的通信协议,需要考虑传感信号和控制信号的传输问题,一定程度上限制了其应用范围。At present, most of the welding seam tracking systems at home and abroad are machine vision systems based on traditional PCs, which mainly include computers, vision sensing systems, image acquisition cards, motion control cards, etc. It is beneficial to be used in some harsh industrial environments; the cost is high, the energy consumption is large, and the cost performance is not high; the installation is difficult, and it is not easy to debug. In addition, the traditional welding seam tracking system needs to formulate complex communication protocols with welding equipment, and needs to consider the transmission of sensing signals and control signals, which limits its application scope to a certain extent.

传统的焊缝跟踪系统需要在焊接前手动输入焊缝类型并采取相应的焊缝图像处理方法,从而严重降低了焊接自动化水平。The traditional welding seam tracking system needs to manually input the welding seam type and adopt the corresponding welding seam image processing method before welding, which seriously reduces the welding automation level.

在现场焊接过程中,基于线结构光视觉传感器检测的焊缝图像信息中存在强烈的噪声干扰,造成焊缝跟踪精度降低。近年来,目标跟踪算法开始应用于焊缝跟踪领域,取得了良好的效果,然而在强噪声的干扰下,跟踪过程中依然存在跟踪漂移导致跟踪失效的问题。During the on-site welding process, there is strong noise interference in the image information of the weld seam detected by the line structured light vision sensor, which reduces the accuracy of the weld seam tracking. In recent years, the target tracking algorithm has been applied to the field of welding seam tracking and achieved good results. However, under the interference of strong noise, there is still the problem of tracking drift leading to tracking failure during the tracking process.

发明内容SUMMARY OF THE INVENTION

本发明为克服上述现有技术所述的焊缝检测速度以及准确率不高的缺陷,提供一种基于独立纠偏型深度学习的焊缝跟踪方法及装置。The present invention provides a welding seam tracking method and device based on independent deviation correction type deep learning in order to overcome the defects of low welding seam detection speed and accuracy described in the prior art.

所述方法包括以下步骤:The method includes the following steps:

S1:采集焊缝结构光图片;S1: Collect structured light pictures of welds;

S2:读取焊缝结构光图片;S2: Read the structured light picture of the weld;

S3:根据焊缝自动跟踪的要求,在焊接开始前需要确定焊缝类型。利用YOLOV3识别到当前焊缝类型并定位焊缝中心位置;S3: According to the requirements of automatic welding seam tracking, the welding seam type needs to be determined before welding starts. Use YOLOV3 to identify the current weld type and locate the center of the weld;

S4:以S3定位的焊缝中心位置作为跟踪目标,并初始化KCF跟踪器;S4: Take the center position of the weld positioned by S3 as the tracking target, and initialize the KCF tracker;

KCF跟踪器的初始化包括选取边界框为正样本,通过循环偏移建立循环矩阵,训练分类器,引入高斯核函数提高分类器性能。The initialization of the KCF tracker includes selecting the bounding box as a positive sample, establishing a cyclic matrix through cyclic offset, training the classifier, and introducing a Gaussian kernel function to improve the performance of the classifier.

S5:焊接开始,利用KCF-YOLOV3算法实时跟踪焊缝;直至焊接结束。S5: The welding starts, and the KCF-YOLOV3 algorithm is used to track the welding seam in real time; until the welding ends.

优选地,焊缝中心位置的定位方法为:Preferably, the positioning method of the center position of the weld is:

YOLOV3在焊缝图像中检测焊缝,会在焊缝中心位置出现目标边界框,故以边界框的中心坐标为焊缝中心位置。YOLOV3 detects the weld in the weld image, and the target bounding box will appear at the center of the weld, so the center coordinate of the bounding box is used as the center of the weld.

优选地,S5包括以下步骤:Preferably, S5 includes the following steps:

S5.1:利用KCF跟踪焊缝,YOLOV3检测焊缝并持续修正跟踪器,防止跟踪漂移;S5.1: Use KCF to track the weld, YOLOV3 detects the weld and continuously corrects the tracker to prevent tracking drift;

S5.2:判断YOLOV3的分类分数是否高于固定值,若是,则执行S5.3,若否,则执行S5.5;S5.2: Determine whether the classification score of YOLOV3 is higher than the fixed value, if so, execute S5.3, if not, execute S5.5;

S5.3:计算KCF与YOLOV3输出焊缝中心位置x轴方向的偏移误差率Po;并判断Po是否大于固定阈值α或等于零,若是,则执行S5.4,若否,则执行S5.5;S5.3: Calculate the offset error rate Po in the x-axis direction of the output weld center position of KCF and YOLOV3 ; and determine whether Po is greater than the fixed threshold α or equal to zero, if so, execute S5.4, if not, execute S5. 5;

S5.4:以YOLOV3的检测结果作为焊缝中心位置;根据YOLOV3检测结果重新初始化KCF跟踪器;S5.4: Use the detection result of YOLOV3 as the center position of the weld; re-initialize the KCF tracker according to the detection result of YOLOV3;

S5.5:以KCF跟踪结果作为焊接中心位置,并实时更新KCF跟踪器;S5.5: Take the KCF tracking result as the welding center position, and update the KCF tracker in real time;

S5.6:根据S5.4初始化的KCF跟踪器或S5.5更新的KCF跟踪器,判断是否是焊缝图像最后一帧,若否,则返回S5.2;若是,则结束焊接。S5.6: According to the KCF tracker initialized in S5.4 or the KCF tracker updated in S5.5, determine whether it is the last frame of the weld image, if not, return to S5.2; if so, end the welding.

优选地,焊缝中心位置偏移误差率Po的计算公式为:Preferably, the calculation formula of the offset error rate P o of the weld center position is:

Figure BDA0002837587820000031
Figure BDA0002837587820000031

式中,x(k)为KCF算法在k时刻预测的焊缝中心位置x轴坐标,x*(k)为YOLO算法在k时刻检测到的焊缝中心位置x轴坐标。In the formula, x(k) is the x-axis coordinate of the weld center position predicted by the KCF algorithm at time k, and x * (k) is the x-axis coordinate of the weld center position detected by the YOLO algorithm at time k.

本发明所述焊接装置可实现所述焊接方法,所述装置包括:工作平台、控制器、竖直方向导轨、水平方向导轨、焊枪夹具、线结构光视觉传感器、伺服电机;The welding device of the present invention can realize the welding method, and the device comprises: a working platform, a controller, a vertical guide rail, a horizontal guide rail, a welding torch fixture, a line structured light vision sensor, and a servo motor;

工作平台用来放置待焊接工件;The working platform is used to place the workpiece to be welded;

控制器、竖直方向导轨、水平方向导轨、焊枪夹具、线结构光视觉传感器、伺服电机设于工作平台上方;The controller, vertical guide rail, horizontal guide rail, welding torch fixture, line structured light vision sensor, and servo motor are arranged above the working platform;

水平方向导轨设置于竖直方向导轨上,并可沿竖直导方向轨上下滑动;The horizontal guide rail is arranged on the vertical guide rail, and can slide up and down along the vertical guide rail;

电机设置于水平方向导轨的一端;The motor is arranged at one end of the horizontal guide rail;

焊枪夹具和线结构光视觉传感器设置于水平方向导轨上;The welding torch fixture and the line structured light vision sensor are arranged on the horizontal guide rail;

通过电机传动可控制焊枪夹具和线结构光视觉传感器在水平方向导轨上沿水平方向移动;Through the motor drive, the welding torch fixture and the line structured light vision sensor can be controlled to move in the horizontal direction on the horizontal direction guide rail;

焊枪夹具用来夹持焊枪;线结构光视觉传感器用来采集焊接点的焊缝结构光图片,并将采集的焊缝结构光图片发送给控制器;The welding torch fixture is used to hold the welding torch; the line structured light vision sensor is used to collect the welded seam structured light pictures of the welding points, and send the collected welded seam structured light pictures to the controller;

控制器控制电机转动。The controller controls the rotation of the motor.

优选地,所述控制器包括上位机和下位机;Preferably, the controller includes an upper computer and a lower computer;

上位机与线结构光视觉传感器连接;The upper computer is connected with the line structured light vision sensor;

线结构光视觉传感器采集焊接点的焊缝结构光图片,并发送给上位机;The line structured light vision sensor collects the welded seam structured light picture of the welding point and sends it to the host computer;

上位机焊缝图像进行分析并将焊缝偏差信息转化为指令发送给下位机;The upper computer analyzes the weld image and converts the weld deviation information into instructions and sends it to the lower computer;

下位机用于接收来自上位机的指令,解析指令内容并转化为相应控制功能,通过向伺服电机驱动器发送控制信号来控制伺服电机。The lower computer is used to receive the command from the upper computer, analyze the content of the command and convert it into the corresponding control function, and control the servo motor by sending control signals to the servo motor driver.

优选地,所述上位机为Raspberry Pi 4b开发板,所述下位机为MINI-STM32单片机。Preferably, the upper computer is a Raspberry Pi 4b development board, and the lower computer is a MINI-STM32 microcontroller.

优选地,所述电机为伺服电机。Preferably, the motor is a servo motor.

优选地,所述竖直方向导轨包括第一固定支架、第一丝杠、手动滑轮;Preferably, the vertical guide rail includes a first fixing bracket, a first lead screw, and a manual pulley;

第一丝杠包括第一螺杆和第一螺母;The first lead screw includes a first screw rod and a first nut;

第一螺杆可转动的设置于第一固定支架上,第一螺杆的一端与手动滑轮同轴连接;通过转动手动滑轮可带动第一螺杆转动;The first screw rod is rotatably arranged on the first fixing bracket, and one end of the first screw rod is coaxially connected with the manual pulley; the first screw rod can be driven to rotate by rotating the manual pulley;

第一螺母与水平方向导轨连接。The first nut is connected with the horizontal guide rail.

优选地,所述水平方向导轨包括第二固定支架、第二丝杠;Preferably, the horizontal guide rail includes a second fixing bracket and a second lead screw;

第二固定支架与第一螺母连接;The second fixing bracket is connected with the first nut;

第二丝杠包括第二螺杆和第二螺母;The second lead screw includes a second screw rod and a second nut;

第二螺杆可转动的设置于第二固定支架上,第二螺杆的一端与电机传动轴同轴连接;通过电机可带动第二螺杆转动;The second screw rod is rotatably arranged on the second fixing bracket, and one end of the second screw rod is coaxially connected with the motor drive shaft; the second screw rod can be driven to rotate by the motor;

第二螺母与焊枪夹具和线结构光视觉传感器连接。The second nut is connected with the welding torch fixture and the wire structured light vision sensor.

与现有技术相比,本发明技术方案的有益效果是:Compared with the prior art, the beneficial effects of the technical solution of the present invention are:

本发明所述焊接装置及焊接方法能够自动识别多种焊缝并精确定位焊缝中心区域。此外,本发明基于核相关滤波(KCF)结合深度学习检测(YOLOV3)的焊缝跟踪方法(KCF-YOLOV3),在KCF算法有可能受噪声干扰导致跟踪漂移的情况下,YOLOV3可以实时定位焊缝中心,并持续修正KCF跟踪器,从而有效抑制跟踪漂移,极大提高焊缝跟踪算法鲁棒性能,令焊缝跟踪精度进一步提高。可有效提高焊缝检测速度以及识别准确率,从而提高焊接效率。The welding device and the welding method of the invention can automatically identify various welding seams and precisely locate the central area of the welding seam. In addition, the present invention is based on the welding seam tracking method (KCF-YOLOV3) based on kernel correlation filtering (KCF) combined with deep learning detection (YOLOV3), in the case that the KCF algorithm may be disturbed by noise and cause tracking drift, YOLOV3 can locate the welding seam in real time Center, and continuously correct the KCF tracker, so as to effectively suppress the tracking drift, greatly improve the robust performance of the welding seam tracking algorithm, and further improve the welding seam tracking accuracy. It can effectively improve the welding seam detection speed and recognition accuracy, thereby improving welding efficiency.

附图说明Description of drawings

图1为实施例1所述一种基于独立纠偏型深度学习的焊缝跟踪方法流程图。FIG. 1 is a flow chart of a welding seam tracking method based on independent deviation correction deep learning according to Embodiment 1. As shown in FIG.

图2为KCF-YOLOV3算法流程图。Figure 2 is the flow chart of the KCF-YOLOV3 algorithm.

图3为实施例1所述一种基于独立纠偏型深度学习的焊缝跟踪装置示意图。FIG. 3 is a schematic diagram of the welding seam tracking device based on the deep learning of the independent deviation correction type according to the first embodiment.

图4为竖直方向导轨和水平方向导轨示意图。FIG. 4 is a schematic diagram of a vertical guide rail and a horizontal guide rail.

图中:1-控制器、2-伺服电机、3-竖直方向导轨、4-水平方向导轨、5-线结构光视觉传感器、6-焊枪夹具、7-焊枪、8-弧焊机、9-工作平台、10-待焊接工件、3.1-第一固定支架、2-第一丝杠、3.3-手动滑轮、4.1-第二丝杠、4.2-第二固定支架。In the picture: 1-controller, 2-servo motor, 3-vertical guide rail, 4-horizontal guide rail, 5-line structured light vision sensor, 6-welding torch fixture, 7-welding torch, 8-arc welding machine, 9 - Working platform, 10 - Workpiece to be welded, 3.1 - First fixing bracket, 2 - First lead screw, 3.3 - Manual pulley, 4.1 - Second lead screw, 4.2 - Second fixing bracket.

具体实施方式Detailed ways

附图仅用于示例性说明,不能理解为对本专利的限制;The accompanying drawings are for illustrative purposes only, and should not be construed as limitations on this patent;

为了更好说明本实施例,附图某些部件会有省略、放大或缩小,并不代表实际产品的尺寸;In order to better illustrate this embodiment, some parts of the drawings are omitted, enlarged or reduced, which do not represent the size of the actual product;

对于本领域技术人员来说,附图中某些公知结构及其说明可能省略是可以理解的。It will be understood by those skilled in the art that some well-known structures and their descriptions may be omitted from the drawings.

下面结合附图和实施例对本发明的技术方案做进一步的说明。The technical solutions of the present invention will be further described below with reference to the accompanying drawings and embodiments.

实施例1:Example 1:

本实施例提供一种基于独立纠偏型深度学习的焊缝跟踪方法。This embodiment provides a welding seam tracking method based on independent deviation correction deep learning.

本实施例所述焊接方法基于核相关滤波(KCF)结合深度学习检测(YOLOV3)的焊缝跟踪方法(KCF-YOLOV3)。在实时焊接过程中,KCF算法通过循环移位构建大量的正负样本,利用脊回归在线训练分类器,利用循环矩阵在傅里叶空间可对角化的性质将矩阵的运算转化为向量的Hadamard积,大大降低了运算量,使算法满足实时性要求,同时利用高斯核函数映射来提高跟踪精度。The welding method described in this embodiment is based on a welding seam tracking method (KCF-YOLOV3) combined with kernel correlation filtering (KCF) and deep learning detection (YOLOV3). In the real-time welding process, the KCF algorithm constructs a large number of positive and negative samples by cyclic shift, uses ridge regression to train the classifier online, and uses the diagonalization property of the cyclic matrix in the Fourier space to convert the operation of the matrix into the Hadamard of the vector. product, which greatly reduces the amount of computation, makes the algorithm meet the real-time requirements, and uses the Gaussian kernel function mapping to improve the tracking accuracy.

传统核相关滤波跟踪是一种短期目标跟踪方法,其局限性在于长时间跟踪时容易积累跟踪误差以及噪声干扰导致模型漂移。焊接过程中强烈弧光、飞溅等噪声会干扰识别焊缝,同时目标模型在噪声环境下保持更新,若长时间跟踪会积累跟踪误差,从而造成跟踪漂移的问题。跟踪漂移发生在焊接过程中会积累跟踪误差,甚至造成工件报废的严重后果,因此保持目标模型准确,避免跟踪漂移对于焊缝跟踪十分重要。通过深度学习方法检测焊缝中心位置,能周期性地修正KCF跟踪器的目标模型,从而令KCF一直准确稳健地跟踪焊缝。The traditional kernel correlation filter tracking is a short-term target tracking method, and its limitation is that it is easy to accumulate tracking errors and noise interference leads to model drift during long-term tracking. During the welding process, strong arc light, splashes and other noises will interfere with the identification of the welding seam. At the same time, the target model is kept updated in a noisy environment. If tracking for a long time will accumulate tracking errors, resulting in tracking drift. Tracking drift occurs in the welding process, which will accumulate tracking errors and even lead to serious consequences of scrapping the workpiece. Therefore, keeping the target model accurate and avoiding tracking drift is very important for welding seam tracking. The center position of the weld seam is detected by the deep learning method, which can periodically correct the target model of the KCF tracker, so that the KCF can always track the weld seam accurately and stably.

YOLOV3是一种以卷积神经网络为基础的深度网络,它是目前目标检测技术的主流。该算法将目标的分类与定位简化为一个回归问题处理,是一种端到端的目标检测算法。YOLOV3的算法特点是具有较高的检测速度以及识别准确率,因此能够实现在嵌入式平台上的实时检测。为了实现基于YOLOV3的焊缝中心位置检测,需要采集大量焊缝图像并对网络模型进行离线训练。为了提高检测器性能,采集的焊缝图像可以是焊前的焊缝图像,也可以是焊接过程中带有一定噪声的焊缝图像,焊缝类型为常见的平板对接型焊缝、搭接焊缝、V型焊缝、角接焊缝、环形焊缝等,以此提高训练样本的多样性与复杂性。YOLOV3 is a deep network based on convolutional neural network, which is currently the mainstream of target detection technology. The algorithm simplifies the classification and localization of targets into a regression problem, and is an end-to-end target detection algorithm. The algorithm of YOLOV3 is characterized by high detection speed and recognition accuracy, so it can realize real-time detection on embedded platforms. In order to realize the weld center position detection based on YOLOV3, it is necessary to collect a large number of weld images and conduct offline training of the network model. In order to improve the performance of the detector, the collected weld image can be the weld image before welding, or it can be the weld image with certain noise during the welding process. Seams, V-welds, fillet welds, annular welds, etc., to increase the diversity and complexity of training samples.

在焊接开始前,开启YOLOV3的焊缝检测功能,从而识别到当前焊缝类型并定位焊缝中心位置;然后,令定位的焊缝中心位置作为跟踪目标,以之初始化KCF跟踪器;接着,焊接开始后KCF负责跟踪焊缝,YOLOV3负责检测焊缝并持续修正跟踪器的目标模型,防止跟踪漂移。焊接过程中,当YOLOV3的分类模块检测到当前焊缝的某一分类分数较高则认为检测的焊缝中心位置定位精度较高。随后计算KCF与YOLOV3输出焊缝中心位置x轴方向的偏移误差率Po,由于焊缝偏差主要产生在x轴方向,故只考虑x轴方向的偏移误差。设置固定阈值α,当Po>α时,则认为KCF跟踪出现漂移,将此时的YOLO算法目标边框赋值KCF算法重新跟踪;当Po≤α时,则认为跟踪到焊缝,用KCF算法继续跟踪;当Po=0时,此时KCF算法丢失目标,通过YOLO算法对KCF算法再次进行初始化实现目标跟踪。Before welding starts, turn on the welding seam detection function of YOLOV3, so as to identify the current welding seam type and locate the center position of the welding seam; then, use the positioned center position of the welding seam as the tracking target to initialize the KCF tracker; then, welding After the start, KCF is responsible for tracking the weld, and YOLOV3 is responsible for detecting the weld and continuously correcting the target model of the tracker to prevent tracking drift. During the welding process, when the classification module of YOLOV3 detects that a certain classification score of the current weld is high, it is considered that the location accuracy of the detected weld center position is high. Then calculate the offset error rate P o of the output weld center position of KCF and YOLOV3 in the x-axis direction. Since the weld seam deviation is mainly generated in the x-axis direction, only the offset error in the x-axis direction is considered. Set a fixed threshold α, when P o >α, it is considered that the KCF tracking drifts, and the target frame of the YOLO algorithm at this time is assigned to the KCF algorithm to re-track; when P o ≤α, it is considered that the welding seam is tracked, and the KCF algorithm is used. Continue to track; when P o =0, the KCF algorithm loses the target at this time, and the KCF algorithm is initialized again through the YOLO algorithm to achieve target tracking.

当出现跟踪漂移现象,需要利用YOLOV3检测算法重检测并找回目标,将当前时刻的YOLOV3检测结果作为焊缝中心位置,同时重新初始化KCF跟踪器。当没有出现跟踪漂移现象,即KCF跟踪结果可信度较高,则将当前时刻的KCF跟踪结果作为焊缝中心位置,同时KCF跟踪器保持在线更新。当前时刻的焊缝中心位置跟踪完毕,继续进行下一帧的焊缝跟踪,不断循环该算法流程直到最后一帧,同时结束焊接。When the tracking drift phenomenon occurs, it is necessary to use the YOLOV3 detection algorithm to re-detect and retrieve the target, use the YOLOV3 detection result at the current moment as the center position of the weld, and re-initialize the KCF tracker. When there is no tracking drift phenomenon, that is, the reliability of the KCF tracking result is high, the KCF tracking result at the current moment is used as the center position of the weld, and the KCF tracker keeps updating online. The welding seam center position tracking at the current moment is completed, and the welding seam tracking of the next frame is continued, and the algorithm process is continuously looped until the last frame, and the welding is ended at the same time.

下面结合图1对本实施例所述方法进行详细说明:本实施例所述焊接方法包括以下步骤:The method described in this embodiment will be described in detail below with reference to FIG. 1 : the welding method described in this embodiment includes the following steps:

S1:通过线结构光视觉传感器采集焊缝结构光图片;S1: The structured light picture of the weld is collected by the line structured light vision sensor;

S2:通过Raspberry Pi 4b读取线结构光视觉传感器采集的图片;S2: Read the pictures collected by the line structured light vision sensor through Raspberry Pi 4b;

S3:在Raspberry Pi 4b中进行焊缝图像处理:(根据焊缝自动跟踪的要求,在焊接开始前需要确定焊缝类型。YOLOV3在焊缝图像中检测焊缝,会在焊缝中心位置出现边界框,同时识别当前焊缝类型);S3: Weld seam image processing in Raspberry Pi 4b: (According to the requirements of automatic welding seam tracking, the type of welding seam needs to be determined before welding starts. YOLOV3 detects the welding seam in the welding seam image, and a boundary will appear at the center of the welding seam box, while identifying the current weld type);

S4:以S3定位的焊缝中心位置作为跟踪目标,并初始化KCF跟踪器;KCF跟踪器的初始化包括选取边界框为正样本,通过循环偏移建立循环矩阵,训练分类器,引入高斯核函数提高分类器性能。S4: Use the center position of the weld positioned by S3 as the tracking target, and initialize the KCF tracker; the initialization of the KCF tracker includes selecting the bounding box as a positive sample, establishing a cyclic matrix through cyclic offset, training the classifier, and introducing a Gaussian kernel function to improve Classifier performance.

S5:焊接开始,利用KCF-YOLOV3算法(如图2所示)实时跟踪焊缝;直至焊接结束。S5: The welding starts, and the KCF-YOLOV3 algorithm (as shown in Figure 2) is used to track the welding seam in real time; until the welding ends.

具体而言,焊缝特征点所在位置为跟踪的边界框的中心坐标,计算当前时刻的焊缝偏差,并根据偏差量传输控制指令至MINI-STM32。Specifically, the position of the weld feature point is the center coordinate of the tracked bounding box, the weld deviation at the current moment is calculated, and the control command is transmitted to the MINI-STM32 according to the deviation.

为防止焊枪频繁运动,MINI-STM32设置了控制死区,当偏差量小于固定阈值,不控制电机;当偏差量大于固定阈值,MINI-STM32传输相应的控制信号至伺服电机驱动器,电机转动指定距离,实时纠偏,直至焊接结束。In order to prevent the welding torch from moving frequently, MINI-STM32 sets a control dead zone. When the deviation is less than the fixed threshold, the motor will not be controlled; when the deviation is greater than the fixed threshold, MINI-STM32 transmits the corresponding control signal to the servo motor driver, and the motor rotates for a specified distance. , real-time correction, until the end of welding.

其中,焊缝中心位置的定位方法为:YOLOV3在焊缝图像中检测焊缝,会在焊缝中心位置出现目标边界框,故以边界框的中心坐标为焊缝中心位置。Among them, the positioning method of the center of the weld is: YOLOV3 detects the weld in the weld image, and the target bounding box will appear at the center of the weld, so the center coordinate of the bounding box is the center of the weld.

进一步地,S5包括以下步骤:Further, S5 includes the following steps:

S5.1:利用KCF跟踪焊缝,YOLOV3检测焊缝并持续修正跟踪器,防止跟踪漂移;S5.1: Use KCF to track the weld, YOLOV3 detects the weld and continuously corrects the tracker to prevent tracking drift;

S5.2:判断YOLOV3的分类分数是否高于固定值,若是,则执行S5.3,若否,则执行S5.5;S5.2: Determine whether the classification score of YOLOV3 is higher than the fixed value, if so, execute S5.3, if not, execute S5.5;

S5.3:计算KCF与YOLOV3输出焊缝中心位置x轴方向的偏移误差率Po;并判断Po是否大于固定阈值α或等于零,若是,则执行S5.4,若否,则实现S5.5;S5.3: Calculate the offset error rate P o of the output weld center position of KCF and YOLOV3 in the x-axis direction; and judge whether P o is greater than the fixed threshold α or equal to zero, if so, execute S5.4, if not, implement S5 .5;

S5.4:以YOLOV3的检测结果作为焊缝中心位置;根据YOLOV3检测结果重新初始化KCF跟踪器;S5.4: Use the detection result of YOLOV3 as the center position of the weld; re-initialize the KCF tracker according to the detection result of YOLOV3;

S5.5:以KCF跟踪结果作为焊接中心位置,并实时更新KCF跟踪器;S5.5: Take the KCF tracking result as the welding center position, and update the KCF tracker in real time;

S5.6:根据S5.4初始化的KCF跟踪器或S5.5更新的KCF跟踪器,判断是否是焊缝图像最后一帧,若否,则返回S5.2;若是,则结束焊接。S5.6: According to the KCF tracker initialized in S5.4 or the KCF tracker updated in S5.5, determine whether it is the last frame of the weld image, if not, return to S5.2; if so, end the welding.

其中,焊缝中心位置偏移误差率Po的计算公式为:Among them, the calculation formula of the offset error rate Po of the weld center position is:

Figure BDA0002837587820000081
Figure BDA0002837587820000081

式中,x(k)为KCF算法在k时刻预测的焊缝中心位置x轴坐标,x*(k)为YOLO算法在k时刻检测到的焊缝中心位置x轴坐标。In the formula, x(k) is the x-axis coordinate of the weld center position predicted by the KCF algorithm at time k, and x * (k) is the x-axis coordinate of the weld center position detected by the YOLO algorithm at time k.

本实施例所述基于核相关滤波(KCF)结合深度学习检测(YOLOV3)的焊缝跟踪方法(KCF-YOLOV3),这是一种抗干扰能力强的目标跟踪算法,能有效解决跟踪漂移问题。The welding seam tracking method (KCF-YOLOV3) based on kernel correlation filtering (KCF) combined with deep learning detection (YOLOV3) described in this embodiment is a target tracking algorithm with strong anti-interference ability, which can effectively solve the tracking drift problem.

本实施例采用的基于深度学习检测算法YOLOV3的焊缝检测,能够自动识别多种焊缝并精确定位焊缝中心区域。YOLOV3的算法特点是具有较高的检测速度以及识别准确率,因此能够实现在嵌入式平台上的实时检测。The welding seam detection based on the deep learning detection algorithm YOLOV3 adopted in this embodiment can automatically identify various welding seams and accurately locate the central area of the welding seam. The algorithm of YOLOV3 is characterized by high detection speed and recognition accuracy, so it can realize real-time detection on embedded platforms.

实施例2:Example 2:

本实施例提供一种基于独立纠偏型深度学习的焊缝跟踪装置,如图3-4所示,所述装置包括:工作平台9、控制器1、竖直方向导轨3、水平方向导轨4、焊枪夹具6、线结构光视觉传感器5、伺服伺服电机2;This embodiment provides a welding seam tracking device based on independent rectification type deep learning, as shown in Figure 3-4, the device includes: a working platform 9, a controller 1, a vertical guide rail 3, a horizontal guide rail 4, Welding torch fixture 6, line structured light vision sensor 5, servo servo motor 2;

工作平台9用来放置待焊接工件10;The working platform 9 is used to place the workpiece 10 to be welded;

控制器1、竖直方向导轨3、水平方向导轨4、焊枪夹具6、线结构光视觉传感器5、伺服伺服电机2设于工作平台9上方;The controller 1, the vertical direction guide rail 3, the horizontal direction guide rail 4, the welding torch fixture 6, the linear structured light vision sensor 5, and the servo servo motor 2 are arranged above the working platform 9;

水平方向导轨4设置于竖直方向导轨3上,并可沿竖直导方向轨3上下滑动;The horizontal guide rail 4 is arranged on the vertical guide rail 3, and can slide up and down along the vertical guide rail 3;

伺服电机2设置于水平方向导轨4的一端;The servo motor 2 is arranged at one end of the guide rail 4 in the horizontal direction;

焊枪夹具6和线结构光视觉传感器5设置于水平方向导轨4上;The welding torch fixture 6 and the linear structured light vision sensor 5 are arranged on the horizontal guide rail 4;

通过伺服电机2传动可控制焊枪夹具6和线结构光视觉传感器5在水平方向导轨4上沿水平方向移动;Driven by the servo motor 2, the welding torch fixture 6 and the linear structured light vision sensor 5 can be controlled to move in the horizontal direction on the horizontal direction guide rail 4;

焊枪夹具6用来夹持焊枪7;线结构光视觉传感器5用来采集焊接点的焊缝结构光图片,并将采集的焊缝结构光图片发送给控制器1;The welding torch fixture 6 is used to hold the welding torch 7; the line structured light visual sensor 5 is used to collect the structured light picture of the welding seam of the welding point, and send the collected structured light picture of the welding seam to the controller 1;

控制器1控制伺服电机2转动。The controller 1 controls the servo motor 2 to rotate.

其中,所述控制器1包括上位机和下位机;Wherein, the controller 1 includes an upper computer and a lower computer;

上位机与线结构光视觉传感器5连接;The upper computer is connected with the line structured light vision sensor 5;

线结构光视觉传感器5采集焊接点的焊缝结构光图片,并发送给上位机;The line structured light vision sensor 5 collects the welded seam structured light picture of the welding point and sends it to the upper computer;

上位机焊缝图像进行分析并将焊缝偏差信息转化为指令发送给下位机;The upper computer analyzes the weld image and converts the weld deviation information into instructions and sends it to the lower computer;

下位机用于接收来自上位机的指令,解析指令内容并转化为相应控制功能,通过向伺服电机驱动器发送控制信号来控制伺服电机2。The lower computer is used to receive the instructions from the upper computer, analyze the content of the instructions and convert them into corresponding control functions, and control the servo motor 2 by sending control signals to the servo motor driver.

所述上位机为Raspberry Pi 4b开发板,所述下位机为MINI-STM32单片机。The upper computer is a Raspberry Pi 4b development board, and the lower computer is a MINI-STM32 microcontroller.

本实施例所述上位机选用Raspberry Pi 4b开发板,它的CPU是64位的1.5GHz四核ARM Cortex-A72,内存是4GB的LPDDR4 SDRAM,存储系统采用的是SD/Micro SD卡;在Raspberry Pi主板上设有四个USB接口、一个以太网接口和HDMI高清视频输出接口,通过这些接口可以与其他外围设备连接,如键盘、鼠标、网线和显示器相连,组成一台功能齐全的计算机,其操作系统基于Linux系统。下位机选用MINI-STM32单片机,它的CPU是ARM32位Cortex-M3,是一款高性能、低成本、低功耗的微控制器。上位机开发板对采集到的焊缝图像进行分析并将焊缝偏差信息转化为指令发送给下位机;上位机通过串口通信与下位机连接,下位机用于接收来自上位机的指令,解析指令内容并转化为相应控制功能,通过向伺服电机2驱动器发送控制信号来控制伺服电机2。In this embodiment, the host computer uses a Raspberry Pi 4b development board. Its CPU is a 64-bit 1.5GHz quad-core ARM Cortex-A72, its memory is 4GB of LPDDR4 SDRAM, and the storage system uses an SD/Micro SD card; There are four USB ports, one Ethernet port and HDMI high-definition video output port on the Pi motherboard. Through these ports, you can connect with other peripheral devices, such as keyboard, mouse, network cable and monitor, to form a fully functional computer. The operating system is based on the Linux system. The lower computer selects MINI-STM32 single-chip microcomputer, and its CPU is ARM32-bit Cortex-M3, which is a high-performance, low-cost, low-power microcontroller. The host computer development board analyzes the collected seam images and converts the weld seam deviation information into instructions and sends them to the lower computer; the upper computer is connected to the lower computer through serial communication, and the lower computer is used to receive instructions from the upper computer and parse the instructions. The content is converted into the corresponding control function, and the servo motor 2 is controlled by sending a control signal to the servo motor 2 driver.

所述竖直方向导轨3包括第一固定支架3.1、第一丝杠3.2、手动滑轮3.3;The vertical guide rail 3 includes a first fixing bracket 3.1, a first lead screw 3.2, and a manual pulley 3.3;

第一丝杠3.2包括第一螺杆和第一螺母;The first lead screw 3.2 includes a first screw rod and a first nut;

第一螺杆可转动的设置于第一固定支架3.1上,第一螺杆的一端与手动滑轮3.3同轴连接;通过转动手动滑轮3.3可带动第一螺杆转动;The first screw is rotatably arranged on the first fixing bracket 3.1, and one end of the first screw is coaxially connected with the manual pulley 3.3; the first screw can be driven to rotate by rotating the manual pulley 3.3;

第一螺母与水平方向导轨4连接。The first nut is connected to the horizontal guide rail 4 .

所述水平方向导轨4包括第二固定支架4.2、第二丝杠4.1;The horizontal guide rail 4 includes a second fixing bracket 4.2 and a second lead screw 4.1;

第二固定支架4.2与第一螺母连接;The second fixing bracket 4.2 is connected with the first nut;

第二丝杠4.1包括第二螺杆和第二螺母;The second screw 4.1 includes a second screw and a second nut;

第二螺杆可转动的设置于第二固定支架4.2上,第二螺杆的一端与伺服电机2传动轴同轴连接;通过伺服电机2可带动第二螺杆转动;The second screw is rotatably arranged on the second fixing bracket 4.2, and one end of the second screw is coaxially connected to the drive shaft of the servo motor 2; the second screw can be driven to rotate by the servo motor 2;

第二螺母与焊枪夹具6和线结构光视觉传感器5连接。The second nut is connected to the welding torch holder 6 and the line structured light vision sensor 5 .

本实施例所述焊接装置可方便装卸在工业机械臂上,焊缝跟踪过程中,机械臂沿焊接路径方向移动完成与工件间的相对运动,水平方向导轨4可使焊枪沿水平方向往复运动完成纠偏。亦可以将本实施例所述焊接装置安装在各类焊接专机上,依靠在水平方向导轨4上移动完成纠偏。The welding device described in this embodiment can be easily installed and unloaded on an industrial manipulator. During the welding seam tracking process, the manipulator moves along the welding path to complete the relative movement with the workpiece, and the horizontal guide 4 can make the welding torch reciprocate in the horizontal direction to complete the movement. Correction. The welding device described in this embodiment can also be installed on various special welding machines, and the deviation can be corrected by moving on the guide rail 4 in the horizontal direction.

本实施例采用基于嵌入式系统的Raspberry Pi 4b开发板替代现有的PC工控机,MINI-STM32单片机替代现有的运动控制卡。该系统体积小、价格便宜、易于装卸,提高了机器视觉监测设备的灵活性、实用性和推广性。In this embodiment, the Raspberry Pi 4b development board based on the embedded system is used to replace the existing PC industrial computer, and the MINI-STM32 single-chip microcomputer is used to replace the existing motion control card. The system is small in size, cheap in price, easy to load and unload, and improves the flexibility, practicability and popularization of machine vision monitoring equipment.

此外,Raspberry Pi 4b是一款基于Linux操作系统的微型计算机,所以本发明提出的算法采用python语言编写。In addition, Raspberry Pi 4b is a microcomputer based on the Linux operating system, so the algorithm proposed in the present invention is written in python language.

且本实施例所述焊接装置可安装于大部分焊接设备,作为一种独立式焊缝纠偏装置,避免了与焊接设备制定复杂通信协议的问题,应用范围广,且易于安装调试。In addition, the welding device described in this embodiment can be installed in most welding equipment. As an independent welding seam deviation correction device, it avoids the problem of formulating complex communication protocols with welding equipment, has a wide range of applications, and is easy to install and debug.

相同或相似的标号对应相同或相似的部件;The same or similar reference numbers correspond to the same or similar parts;

附图中描述位置关系的用语仅用于示例性说明,不能理解为对本专利的限制;The terms describing the positional relationship in the accompanying drawings are only used for exemplary illustration, and should not be construed as a limitation on this patent;

显然,本发明的上述实施例仅仅是为清楚地说明本发明所作的举例,而并非是对本发明的实施方式的限定。对于所属领域的普通技术人员来说,在上述说明的基础上还可以做出其它不同形式的变化或变动。这里无需也无法对所有的实施方式予以穷举。凡在本发明的精神和原则之内所作的任何修改、等同替换和改进等,均应包含在本发明权利要求的保护范围之内。Obviously, the above-mentioned embodiments of the present invention are only examples for clearly illustrating the present invention, and are not intended to limit the embodiments of the present invention. For those of ordinary skill in the art, changes or modifications in other different forms can also be made on the basis of the above description. There is no need and cannot be exhaustive of all implementations here. Any modification, equivalent replacement and improvement made within the spirit and principle of the present invention shall be included within the protection scope of the claims of the present invention.

Claims (8)

1. A welding seam tracking method based on independent deviation correction type deep learning is characterized by comprising the following steps:
s1: collecting a welding seam structure light picture;
s2: reading a welding seam structure light picture;
s3: identifying the current weld type and positioning the center position of the weld by using YOLOV 3; the method for positioning the center position of the welding seam comprises the following steps: the YOLOV3 detects the weld in the weld image, and a target boundary frame appears at the center position of the weld, so the center coordinate of the boundary frame is taken as the center position of the weld;
s4: taking the welding seam center position positioned by S3 as a tracking target, and initializing a KCF tracker;
s5: the welding is started, and the KCF-YOLOV3 algorithm is used for tracking the welding seam in real time; until the welding is finished;
s5 includes the steps of:
s5.1: the KCF is utilized to track the welding seam, and the YOLOV3 detects the welding seam and continuously corrects the tracker to prevent tracking drift;
s5.2: judging whether the classification score of the Yolov3 is higher than a fixed value, if so, executing S5.3, and if not, executing S5.5;
s5.3: calculating offset error rate P of KCF and YOLOV3 in x-axis direction of output weld center positiono(ii) a And judging PoIf the value is greater than the fixed threshold value alpha or equal to zero, if so, executing S5.4; if not, executing S5.5;
s5.4: taking the detection result of YOLOV3 as the center position of the weld joint; reinitializing the KCF tracker according to a detection result of YOLOV 3;
s5.5: taking a KCF tracking result as a welding center position, and updating a KCF tracker in real time;
s5.6: judging whether the frame is the last frame of the welding seam image according to the KCF tracker initialized in the S5.4 or the KCF tracker updated in the S5.5, and if not, returning to the S5.2; if yes, welding is finished.
2. The weld joint tracking method based on the independent correction type deep learning according to claim 1, characterized in that the error rate P of the deviation of the center position of the weld joint isoThe calculation formula of (2) is as follows:
Figure FDA0003595293570000011
wherein x (k) is x-axis coordinate of the weld center position predicted by the KCF algorithm at k moment, x*(k) And the x-axis coordinate of the weld center position detected by the YOLO algorithm at the moment k.
3. A weld tracking device based on independent deviation correction type deep learning, characterized in that the device comprises: the welding gun comprises a working platform, a controller, a vertical guide rail, a horizontal guide rail, a welding gun clamp, a line structured light vision sensor and a servo motor;
the working platform is used for placing a workpiece to be welded;
the controller, the vertical guide rail, the horizontal guide rail, the welding gun clamp, the line structured light vision sensor and the servo motor are arranged above the working platform;
the horizontal guide rail is arranged on the vertical guide rail and can slide up and down along the vertical guide rail;
the motor is arranged at one end of the guide rail in the horizontal direction;
the welding gun clamp and the line structured light vision sensor are arranged on the horizontal guide rail;
the welding gun clamp and the line structured optical vision sensor can be controlled to move along the horizontal direction on the horizontal direction guide rail through the transmission of the motor;
the welding gun clamp is used for clamping a welding gun; the linear structure light vision sensor is used for collecting a welding seam structure light picture of a welding point and sending the collected welding seam structure light picture to the controller;
the controller tracks the welding seam on the workpiece to be welded by adopting the welding seam tracking method based on the independent correction type deep learning of claim 1 or 2, and controls the motor to rotate according to the welding seam tracking result.
4. The weld joint tracking device based on the independent correction type deep learning according to claim 3, wherein the controller comprises an upper computer and a lower computer;
the upper computer is connected with the line structured light vision sensor;
the line structure light vision sensor collects a welding line structure light picture of a welding point and sends the welding line structure light picture to the upper computer;
analyzing the weld image of the upper computer, converting the weld deviation information into an instruction and sending the instruction to the lower computer;
the lower computer is used for receiving the instruction from the upper computer, analyzing the instruction content, converting the instruction content into a corresponding control function and controlling the servo motor by sending a control signal to the servo motor driver.
5. The weld joint tracking device based on the independent deviation correction type deep learning of claim 4, wherein the upper computer is a Raspberry Pi 4b development board, and the lower computer is a MINI-STM32 single chip microcomputer.
6. The weld tracking device based on the independent correction type deep learning of claim 5, wherein the motor is a servo motor.
7. The weld joint tracking device based on the independent correction type deep learning according to any one of claims 4 to 6, wherein the vertical direction guide rail comprises a first fixed bracket, a first lead screw and a manual pulley;
the first lead screw comprises a first screw rod and a first nut;
the first screw rod is rotatably arranged on the first fixing support, and one end of the first screw rod is coaxially connected with the manual pulley; the first screw rod can be driven to rotate by rotating the manual pulley;
the first nut is connected with the horizontal guide rail.
8. The weld joint tracking device based on the independent correction type deep learning of claim 7, wherein the horizontal guide rail comprises a second fixed bracket and a second lead screw;
the second fixing bracket is connected with the first nut;
the second lead screw comprises a second screw rod and a second nut;
the second screw rod is rotatably arranged on the second fixed support, and one end of the second screw rod is coaxially connected with the motor transmission shaft; the second screw rod can be driven to rotate by the motor;
the second nut is connected with the welding gun clamp and the line structured light vision sensor.
CN202011477237.0A 2020-12-15 2020-12-15 A welding seam tracking method and device based on independent rectification deep learning Active CN112589232B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011477237.0A CN112589232B (en) 2020-12-15 2020-12-15 A welding seam tracking method and device based on independent rectification deep learning

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011477237.0A CN112589232B (en) 2020-12-15 2020-12-15 A welding seam tracking method and device based on independent rectification deep learning

Publications (2)

Publication Number Publication Date
CN112589232A CN112589232A (en) 2021-04-02
CN112589232B true CN112589232B (en) 2022-05-20

Family

ID=75195709

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011477237.0A Active CN112589232B (en) 2020-12-15 2020-12-15 A welding seam tracking method and device based on independent rectification deep learning

Country Status (1)

Country Link
CN (1) CN112589232B (en)

Families Citing this family (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113313106A (en) * 2021-04-14 2021-08-27 深圳市睿达科技有限公司 Feeding deviation rectifying method and device, computer equipment and storage medium
CN114043081B (en) * 2021-11-24 2023-12-22 苏州全视智能光电有限公司 Multi-weld-joint type feature point identification method and system for laser welding
CN114029588A (en) * 2021-11-26 2022-02-11 江苏永大化工设备有限公司 Automatic adjusting system for gas shielded welding process parameters
CN114266974B (en) * 2021-12-23 2024-09-27 福州大学 Automatic positioning welding method based on deep learning
CN114260547B (en) * 2021-12-23 2022-07-01 山东大学 A tungsten pole position correction method for narrow-gap rotating arc GTAW based on deep learning algorithm
CN114932292B (en) * 2022-05-27 2023-09-26 华南理工大学 Narrow-gap passive vision weld joint tracking method and system
CN114749849B (en) * 2022-06-01 2023-09-01 江苏徐工工程机械研究院有限公司 Welding control method, device and system
CN116117273B (en) * 2023-03-01 2024-04-19 广东工业大学 An adaptive feedforward welding correction device and method
CN117840757A (en) * 2024-02-22 2024-04-09 江苏凯乐金属科技有限公司 Aluminum alloy profile arc welding equipment

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US3743776A (en) * 1970-05-05 1973-07-03 J Angely Device for tracing seams for welding by electron bombardment
CN106271081A (en) * 2016-09-30 2017-01-04 华南理工大学 Three coordinate rectangular robot line laser seam tracking system and trackings thereof
CN109492688A (en) * 2018-11-05 2019-03-19 深圳步智造科技有限公司 Welding seam tracking method, device and computer readable storage medium
CN109604777A (en) * 2017-12-07 2019-04-12 淮安信息职业技术学院 Welding seam traking system and method based on laser structure light
CN110480127A (en) * 2019-08-12 2019-11-22 广东工业大学 A kind of seam tracking system and method based on structured light visual sensing
CN110706266A (en) * 2019-12-11 2020-01-17 北京中星时代科技有限公司 Aerial target tracking method based on YOLOv3
CN210908467U (en) * 2019-07-16 2020-07-03 常州坤达焊接技术有限公司 Welding device for realizing welding seam tracking

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US3743776A (en) * 1970-05-05 1973-07-03 J Angely Device for tracing seams for welding by electron bombardment
CN106271081A (en) * 2016-09-30 2017-01-04 华南理工大学 Three coordinate rectangular robot line laser seam tracking system and trackings thereof
CN109604777A (en) * 2017-12-07 2019-04-12 淮安信息职业技术学院 Welding seam traking system and method based on laser structure light
CN109492688A (en) * 2018-11-05 2019-03-19 深圳步智造科技有限公司 Welding seam tracking method, device and computer readable storage medium
CN210908467U (en) * 2019-07-16 2020-07-03 常州坤达焊接技术有限公司 Welding device for realizing welding seam tracking
CN110480127A (en) * 2019-08-12 2019-11-22 广东工业大学 A kind of seam tracking system and method based on structured light visual sensing
CN110706266A (en) * 2019-12-11 2020-01-17 北京中星时代科技有限公司 Aerial target tracking method based on YOLOv3

Also Published As

Publication number Publication date
CN112589232A (en) 2021-04-02

Similar Documents

Publication Publication Date Title
CN112589232B (en) A welding seam tracking method and device based on independent rectification deep learning
CN107081787B (en) Motion characteristic detection method based on built-in sensor signal of industrial robot
CN104384765B (en) Based on the automatic soldering method of threedimensional model and machine vision
CN103762522B (en) A kind of inspection robot for high-voltage line independently look for line control method
CN110064819A (en) The extraction of cylinder longitudinal seam characteristic area, welding seam tracking method and system based on structure light
CN111604942A (en) Object detection device, control device, and computer program for object detection
CN109465829A (en) A Geometric Parameter Identification Method of Industrial Robot Based on Transformation Matrix Error Model
CN110146017B (en) Industrial robot repeated positioning precision measuring method
CN111299762B (en) Laser real-time weld joint tracking method for separating strong noise interference
CN203310407U (en) Mechanical arm positioning precision calibration device
CN105364266A (en) Mechanical arm motion trail adjusting system and method
CN101377418A (en) Device and method for detecting contact type large-scale special-shaped glass outline based on rotating-rectilinear movements
CN111238367B (en) Three-dimensional arm shape measuring method and device for rope-driven mechanical arm
CN111536872A (en) Two-dimensional plane distance measuring device and method based on vision and mark point identification device
Liu et al. An approach to robot welding path autonomous planning of the intersection weldment based on 3D visual perception
CN112001945A (en) Multi-robot monitoring method suitable for production line operation
CN115078961A (en) Desktop-level circuit board detection device and method based on visual feedback mechanical arm
CN104111663A (en) Three-dimensional closed-loop feedback control method for automatic rocket inertia unit target prism collimation
CN116393982B (en) Screw locking method and device based on machine vision
CN117523575A (en) Intelligent instrument reading method and system based on inspection robot
CN107942748B (en) Mechanical arm space dynamic obstacle avoidance induction bracelet and control system
CN1419104A (en) Object space position detector
CN112013868B (en) An adaptive parameter police dog attitude estimation method based on visual inertial navigation odometer
CN110490834A (en) The object recognition and detection method of foreign matter device is removed based on laser
CN105786025B (en) A kind of cantilever crane front end vertical direction positioning system and localization method

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant