摘要
日常生活中拍摄二维码往往会有多种角度,这会影响识别的准确率。为了通过透视变换对二维码进行矫正,须检测到二维码的四个角点。首先利用爬虫获取二维码图片,结合OpenCV合成更多的数据集。然后基于YOLO v5算法,修改其输出层,同时添加角点回归的损失函数,实现对图片中二维码的角点检测。最后根据检测得到的角点,透视变换得到一个矫正后的二维码,从而提高识别的准确率。
The QR codes shot in daily life often has a variety of angles,which will affect the accuracy of recognition.In order to correct the QR codes by perspective change,four corners of the QR codes need to be detected.In this paper,the crawler is first used to obtain QR codes images,and more data sets are synthesized by combining OpenCV.Then,based on the YOLO v5 algorithm,the output layer is modified,and the loss function of corner regression is added to realize the corner detection of the QR codes in the picture.Finally,according to the detected corner,perspective transformation can obtain a corrected QR code to improve the recognition accuracy.
作者
蔡若君
胡玉佩
CAI Ruojun;HU Yupei(Guangdong Vocational College of Post and Telecom,Guangzhou,Guangdong,China 510630)
出处
《湖南邮电职业技术学院学报》
2023年第2期1-4,共4页
Journal of Hunan Post and Telecommunication College
基金
2021年广东省继续教育质量提升工程项目“通信原理在线教育课程”(项目编号:JXJYGC2021)。