《计算机应用》唯一官方网站 ›› 2023, Vol. 43 ›› Issue (S2): 89-98.DOI: 10.11772/j.issn.1001-9081.2023010011
李文杰1, 张足生1(), 董阿妮2, 周坤晓1, 郭小红1
收稿日期:
2023-01-06
修回日期:
2023-04-01
接受日期:
2023-04-03
发布日期:
2023-06-06
出版日期:
2023-12-31
通讯作者:
张足生
作者简介:
李文杰(1997—),男,山西大同人,硕士研究生,CCF会员,主要研究方向:计算机视觉;基金资助:
Wenjie LI1, Zusheng ZHANG1(), Ani DONG2, Kunxiao ZHOU1, Xiaohong GUO1
Received:
2023-01-06
Revised:
2023-04-01
Accepted:
2023-04-03
Online:
2023-06-06
Published:
2023-12-31
Contact:
Zusheng ZHANG
摘要:
针对现有车牌生成算法不能解决真实车牌数据集存在的数量少、多样性不足、字符标签不均衡、包含个人隐私等问题,提出一种改进循环生成对抗网络(CycleGAN)车牌生成算法。该算法由三部分组成:根据标准合成虚拟车牌,用仿射变换将虚拟车牌嵌入背景图像,然后由改进CycleGAN生成车牌图像样本。该算法通过引入权重解调机制解决了生成图像的白斑问题;利用重要区域损失、通道注意力与空间注意力实现了仅生成车牌部分的同时,保留了背景环境;采用最小二乘损失(LSLoss)改善了生成图像质量。已公开发布了20 000多张包括大倾角、远距离、模糊、复杂光照、天气条件等场景的生成车牌图像数据集,并通过对比实验验证了所提算法的有效性。在OpenITS、CLPD、CCPD(11K)验证集上的实验结果表明:在车牌检测任务中,与真实训练集的性能相近;在车牌识别任务中,识别精度相较于真实数据集分别提高了74.0%、28.0%、48.7%,相较于Bj?rklund、Duan、Han的算法都有3.0%以上提高。所提算法可生成数量多、多样性高、字符标签均衡、无隐私问题的车牌数据,能够对车牌检测与识别算法的训练提供有效支持。
中图分类号:
李文杰, 张足生, 董阿妮, 周坤晓, 郭小红. 改进循环生成对抗网络的车牌数据集自动生成算法[J]. 计算机应用, 2023, 43(S2): 89-98.
Wenjie LI, Zusheng ZHANG, Ani DONG, Kunxiao ZHOU, Xiaohong GUO. Automatic generation algorithm of license plate dataset based on improved CycleGAN[J]. Journal of Computer Applications, 2023, 43(S2): 89-98.
数据集 | 样本数 | 数量足够 | 多样性 | 字符均衡 |
---|---|---|---|---|
OpenITS[ | 1 402 | × | × | √ |
AOLP[ | 2 049 | × | √ | × |
PKUdata[ | 3 977 | × | √ | × |
CLPD[ | 1 400 | × | √ | √ |
CCPD[ | 250 000 | √ | √ | × |
表1 目前公开的国内各地区车牌数据集
数据集 | 样本数 | 数量足够 | 多样性 | 字符均衡 |
---|---|---|---|---|
OpenITS[ | 1 402 | × | × | √ |
AOLP[ | 2 049 | × | √ | × |
PKUdata[ | 3 977 | × | √ | × |
CLPD[ | 1 400 | × | √ | √ |
CCPD[ | 250 000 | √ | √ | × |
场景 | 起点域 | 目标域 | 描述 |
---|---|---|---|
Base | 10 000 | 10 000 | 常规场景 |
Rotate | 2 000 | 2 000 | 大旋转角场景 |
Tilt | 2 000 | 2 000 | 大倾斜角场景 |
Db | 2 000 | 2 000 | 光度不均场景 |
Fn | 2 000 | 2 000 | 远距离场景 |
Blur | 2 000 | 2 000 | 模糊场景 |
Weather | 1 000 | 1 000 | 天气因素场景 |
Challenge | 807 | 807 | 挑战性的场景 |
表2 改进CycleGAN的训练集构成
场景 | 起点域 | 目标域 | 描述 |
---|---|---|---|
Base | 10 000 | 10 000 | 常规场景 |
Rotate | 2 000 | 2 000 | 大旋转角场景 |
Tilt | 2 000 | 2 000 | 大倾斜角场景 |
Db | 2 000 | 2 000 | 光度不均场景 |
Fn | 2 000 | 2 000 | 远距离场景 |
Blur | 2 000 | 2 000 | 模糊场景 |
Weather | 1 000 | 1 000 | 天气因素场景 |
Challenge | 807 | 807 | 挑战性的场景 |
数据集 | 样本数 | 环境多样性 | 字符均衡 |
---|---|---|---|
OpenITS | 1 402 | 固定视角;昼 | 31地区 |
PKUdata | 3 799 | 固定视角;昼夜 | 仅皖 |
CLPD | 1 200 | 多变 | 31地区 |
CCPD(11K) | 11 232 | 多变 | 31地区 |
表3 验证集构成
数据集 | 样本数 | 环境多样性 | 字符均衡 |
---|---|---|---|
OpenITS | 1 402 | 固定视角;昼 | 31地区 |
PKUdata | 3 799 | 固定视角;昼夜 | 仅皖 |
CLPD | 1 200 | 多变 | 31地区 |
CCPD(11K) | 11 232 | 多变 | 31地区 |
算法 | LRA | ARA | MCRA |
---|---|---|---|
CycleGAN(no improvements) | 74.3 | 93.7 | 79.6 |
+ WD | 90.4 | 95.5 | 93.8 |
+ LSLoss | 92.3 | 95.6 | 95.7 |
+ CAM & SAM | 92.6 | 95.6 | 96.0 |
+ SALoss | 95.1 | 96.0 | 98.7 |
表4 CLPD验证集下各个改进消融实验结果 ( %)
算法 | LRA | ARA | MCRA |
---|---|---|---|
CycleGAN(no improvements) | 74.3 | 93.7 | 79.6 |
+ WD | 90.4 | 95.5 | 93.8 |
+ LSLoss | 92.3 | 95.6 | 95.7 |
+ CAM & SAM | 92.6 | 95.6 | 96.0 |
+ SALoss | 95.1 | 96.0 | 98.7 |
算法 | 测试集 | AP/% |
---|---|---|
YOLOv5[ | CCPD(20K) | 99.1 |
本文算法生成图像 | 98.9 | |
SSD[ | CCPD(20K) | 94.1 |
本文算法生成图像 | 94.2 | |
Faster-RCNN[ | CCPD(20K) | 92.1 |
本文算法生成图像 | 93.1 | |
RPNet[ | CCPD(20K) | 94.2 |
本文算法生成图像 | 94.2 |
表5 基于CCPD真实数据训练的不同检测算法结果对比
算法 | 测试集 | AP/% |
---|---|---|
YOLOv5[ | CCPD(20K) | 99.1 |
本文算法生成图像 | 98.9 | |
SSD[ | CCPD(20K) | 94.1 |
本文算法生成图像 | 94.2 | |
Faster-RCNN[ | CCPD(20K) | 92.1 |
本文算法生成图像 | 93.1 | |
RPNet[ | CCPD(20K) | 94.2 |
本文算法生成图像 | 94.2 |
数据集 | AP/% | 不同场景的MCRA/% | ||||||
---|---|---|---|---|---|---|---|---|
Base | Rotate | Tilt | Db | Fn | Weather | Challenge | ||
Björklund[ | 33.7 | 47.2 | 42.3 | 39.5 | 15.7 | 12.9 | 25.4 | 18.7 |
Duan[ | 50.7 | 79.1 | 68.4 | 64.2 | 33.1 | 67.6 | 43.8 | 32.5 |
Han-pix2pix[ | 89.3 | 90.7 | 93.0 | 93.3 | 84.2 | 82.9 | 85.6 | 80.4 |
Han-CycleGAN[ | 93.7 | 95.1 | 94.2 | 93.8 | 87.6 | 82.6 | 86.6 | 84.3 |
本文算法生成图像 | 98.9 | 99.3 | 99.9 | 99.7 | 99.1 | 97.3 | 99.7 | 95.0 |
CCPD[ | 99.1 | 99.5 | 99.7 | 99.8 | 99.4 | 97.7 | 99.5 | 95.4 |
表6 与基线算法检测任务结果的对比
数据集 | AP/% | 不同场景的MCRA/% | ||||||
---|---|---|---|---|---|---|---|---|
Base | Rotate | Tilt | Db | Fn | Weather | Challenge | ||
Björklund[ | 33.7 | 47.2 | 42.3 | 39.5 | 15.7 | 12.9 | 25.4 | 18.7 |
Duan[ | 50.7 | 79.1 | 68.4 | 64.2 | 33.1 | 67.6 | 43.8 | 32.5 |
Han-pix2pix[ | 89.3 | 90.7 | 93.0 | 93.3 | 84.2 | 82.9 | 85.6 | 80.4 |
Han-CycleGAN[ | 93.7 | 95.1 | 94.2 | 93.8 | 87.6 | 82.6 | 86.6 | 84.3 |
本文算法生成图像 | 98.9 | 99.3 | 99.9 | 99.7 | 99.1 | 97.3 | 99.7 | 95.0 |
CCPD[ | 99.1 | 99.5 | 99.7 | 99.8 | 99.4 | 97.7 | 99.5 | 95.4 |
训练集 | 样本数/103 | 验证集LRA/% | |||
---|---|---|---|---|---|
OpenITS | PKUdata | CCPD(11K) | CLPD | ||
CCPD(20K)[ | 20 | 57.3 | 98.8 | 66.6 | 74.3 |
CCPD(100K)[ | 100 | 66.3 | 99.4 | 88.0 | 92.7 |
Björklund[ | 20 | 54.4 | 35.7 | 17.6 | 28.9 |
Duan[ | 20 | 77.4 | 73.9 | 27.8 | 33.3 |
Han-pix2pix[ | 20 | 90.0 | 89.1 | 74.7 | 79.9 |
Han-CycleGAN[ | 20 | 95.9 | 93.6 | 92.4 | 87.0 |
本文算法生成图像 | 20 | 99.7 | 98.8 | 99.0 | 95.1 |
CCPD(20K) +本文算法生成图像 | 40 | 99.9 | 99.1 | 99.3 | 93.0 |
表7 与基线算法识别任务结果的对比
训练集 | 样本数/103 | 验证集LRA/% | |||
---|---|---|---|---|---|
OpenITS | PKUdata | CCPD(11K) | CLPD | ||
CCPD(20K)[ | 20 | 57.3 | 98.8 | 66.6 | 74.3 |
CCPD(100K)[ | 100 | 66.3 | 99.4 | 88.0 | 92.7 |
Björklund[ | 20 | 54.4 | 35.7 | 17.6 | 28.9 |
Duan[ | 20 | 77.4 | 73.9 | 27.8 | 33.3 |
Han-pix2pix[ | 20 | 90.0 | 89.1 | 74.7 | 79.9 |
Han-CycleGAN[ | 20 | 95.9 | 93.6 | 92.4 | 87.0 |
本文算法生成图像 | 20 | 99.7 | 98.8 | 99.0 | 95.1 |
CCPD(20K) +本文算法生成图像 | 40 | 99.9 | 99.1 | 99.3 | 93.0 |
训练集 | 样本数/103 | LRA/% | ARA/% | MCRA/% |
---|---|---|---|---|
CCPD(20K) | 20 | 74.3 | 93.7 | 79.6 |
本文算法生成图像 | 20 | 95.1 | 96.0 | 98.7 |
组合训练集 | 40 | 93.0 | 97.4 | 96.7 |
表8 真实数据与生成数据详细指标对比
训练集 | 样本数/103 | LRA/% | ARA/% | MCRA/% |
---|---|---|---|---|
CCPD(20K) | 20 | 74.3 | 93.7 | 79.6 |
本文算法生成图像 | 20 | 95.1 | 96.0 | 98.7 |
组合训练集 | 40 | 93.0 | 97.4 | 96.7 |
1 | NAWARATNE R, KAHAWALA S, NGUYEN S, et al. A generative latent space approach for real-time road surveillance in smart cities[J]. IEEE Transactions on Industrial Informatics, 2021, 17(7): 4872-4881. 10.1109/tii.2020.3037286 |
2 | DU S, IBRAHIM M, SHEHATA M, et al. Automatic License Plate Recognition (ALPR): a state-of-the- art review[J]. IEEE Transactions on Circuits and Systems for Video Technology, 2013, 23(2): 322-336. 10.1109/tcsvt.2012.2203741 |
3 | ZHAN X Y, LI R, UKKUSURI S V. Lane-based real-time queue length estimation using license plate recognition data[J]. Transportation Research Part C,Emerging Technologies, 2015, 57: 85-102. 10.1016/j.trc.2015.06.001 |
4 | OpenITS联盟. OpenData V 3.0——功能车牌图像库数据[DS/OL]. [2022-04-10]. . |
5 | GONCALVES G, SILVA S DA, MENOTTI D, et al. Benchmark for license plate character segmentation[J]. Journal of Electronic Imaging, 2016, 25(5): 053034. 10.1117/1.jei.25.5.053034 |
6 | YUAN Y L, ZOU W B, ZHAO Y, et al. A robust and efficient approach to license plate detection[J]. IEEE Transactions on Image Processing, 2016, 26(3): 1102-1114. 10.1109/tip.2016.2631901 |
7 | ZHANG L J, WANG P, LI H, et al. A robust attentional framework for license plate recognition in the wild[J]. IEEE Transactions on Intelligent Transportation Systems, 2021, 22(11): 1-10. 10.1109/tits.2020.3000072 |
8 | XU Z B, YANG W, MENG A J, et al. Towards end-to-end license plate detection and recognition: a large dataset and baseline [C]// Proceedings of the 15th European Conference on Computer Vision. Cham: Springer, 2018: 261-277. 10.1007/978-3-030-01261-8_16 |
9 | BJÖRKLUND T, FIANDROTTI A, ANNARUMMA M, et al. Robust license plate recognition using neural networks trained on synthetic images[J]. Pattern Recognition, 2019, 93: 134-146. 10.1016/j.patcog.2019.04.007 |
10 | WANG J L, HE H, QIAN X S, et al. Sequence recognition of Chinese license plates[J]. Neurocomputing, 2018, 317: 149-158. 10.1016/j.neucom.2018.08.023 |
11 | SILVANO G, RIBEIRO V, GREATI V, et al. Synthetic image generation for training deep learning-based automated license plate recognition systems on the Brazilian Mercosur standard[J]. Design Automation for Embedded Systems, 2021, 25(2): 113-133. 10.1007/s10617-020-09241-7 |
12 | GOODFELLOW I, JEAN P, MEHDI M, et al. Generative adversarial nets[J]. Communications of the ACM, 2020, 63(11): 139-144. 10.1145/3422622 |
13 | GU J J, SHEN Y J, ZHOU B L, et al. Image processing using multi-code GAN prior [C]// Proceedings of the 33rd IEEE/CVF Conference on Computer Vision and Pattern Recognition. Piscataway, NJ: IEEE, 2020: 3009-3018. 10.1109/cvpr42600.2020.00308 |
14 | LI C X, XU K, ZHU J, et al. Triple generative adversarial nets[C]// Proceedings of the 31st International Conference on Neural Information Processing Systems. New York: ACM, 2017: 4091-4101. |
15 | ZHENG Z D, ZHENG L, YANG Y, et al. Unlabeled samples generated by GAN improve the person re-identification baseline in vitro [C]// Proceedings of the 16th IEEE International Conference Computer Vision. Piscataway, NJ: IEEE, 2017: 3774-3782. 10.1109/iccv.2017.405 |
16 | 段宾,符祥,江毅,等.结合GAN的轻量级模糊车牌识别算法[J].中国图象图形学报, 2020, 25(9): 1813-1824. 10.11834/jig.190604 |
17 | HAN B-G, LEE J-T, K-T LIM, et al. License plate image generation using generative adversarial networks for end-to-end license plate char- acter recognition from a small set of real images[J]. Applied Sciences, 2020, 10(8): 2780-2795. 10.3390/app10082780 |
18 | ZHU J Y, PARK T, ISOLA P, et al. Unpaired image-to-image translation using cycle-consistent adversarial networks [C]// Proceedings of the 16th IEEE International Conference on Computer Vision. Piscataway, NJ: IEEE, 2017: 2242-2251. 10.1109/iccv.2017.244 |
19 | 中华人民共和国公安部. 中华人民共和国机动车号牌: [S].北京:中国标准出版社, 2014: 1-11. |
20 | 中华人民共和国公安部. 中华人民共和国机动车号牌: [S].北京:中国标准出版社, 2018: 1-11. |
21 | WOO S, PARK J, LEE J Y, et al. CBAM: Convolutional block attention module [C]// Proceedings of the 15th European Conference on Computer Vision. Cham: Springer, 2018: 3-19. 10.1007/978-3-030-01234-2_1 |
22 | TERO K, SAMULI L, MIIKA A, et al. Analyzing and improving the image quality of StyleGAN [C]// Proceedings of the 33rd IEEE/CVF Conference on Computer Vision and Pattern Recognition. Piscataway, NJ: IEEE, 2020: 8107-8116. 10.1109/cvpr42600.2020.00813 |
23 | MAO X D, QING L, XIE H R, et al. Least squares generative adversarial networks [C]// Proceedings of the 16th IEEE International Conference on Computer Vision. Piscataway, NJ: IEEE, 2017: 2813-2821. 10.1109/iccv.2017.304 |
24 | ULTRALYTICS. YOLOv5[CP/OL]. [2022-12-09]. . 10.1117/1.jei.31.3.033033 |
25 | LIU W, ANGUELOV D, ERHAN D, et al. SSD: single shot MultiBox detector [C]// Proceedings of the 13th European Conference on Computer Vision. Cham: Springer, 2016: 21-37. 10.1007/978-3-319-46448-0_2 |
26 | REN S Q, HE K M, GIRSHICK R, et al. Faster R-CNN: Towards real-time object detection with region proposal networks[J]. IEEE Transactions on Pattern Analysis and Machine Intelligence, 2017, 39(6): 1137-1149. 10.1109/tpami.2016.2577031 |
27 | ZHERZDEV S, GRUZDEV A. LPRNet: License plate recognition via deep neural networks [EB/OL]. [2022-06-14]. . |
[1] | 李嘉元, 程江华, 刘通, 程榜, 潘乐昊. 基于密集连接的红外可见光图像融合方法[J]. 《计算机应用》唯一官方网站, 2023, 43(S2): 163-167. |
[2] | 周启宸, 王伯超. 基于改进YOLOv7的太阳能电池片表面缺陷检测[J]. 《计算机应用》唯一官方网站, 2023, 43(S2): 223-228. |
[3] | 石彬, 成苗, 张绍兵, 何莲. 半监督塑封烟盒退化图像修复算法[J]. 《计算机应用》唯一官方网站, 2023, 43(S2): 238-243. |
[4] | 莫桂棋, 夏益民, 邢延, 李卫军, 蔡述庭. 面向集成电路拥塞预测的版图数据扩充方法[J]. 《计算机应用》唯一官方网站, 2023, 43(S2): 261-267. |
[5] | 文含, 付忠良, 赵莹, 姚宇, 刘爱连. 基于多模态融合注意力的肝细胞癌疗效预测方法[J]. 《计算机应用》唯一官方网站, 2023, 43(S2): 41-46. |
[6] | 郝铎, 曾令飞, 李成伟. 基于变分模态分解和长短期记忆网络的大平移抖动电子稳像算法[J]. 《计算机应用》唯一官方网站, 2023, 43(S2): 168-175. |
[7] | 魏雄, 王子樊. 融合多尺度卷积和BiGRU网络的人类活动识别模型[J]. 《计算机应用》唯一官方网站, 2023, 43(S2): 72-76. |
[8] | 张昀枭, 吴晓红, 唐荔莉, 徐庆华, 王斌, 何小海. 基于多模态数据的阿尔兹海默病分类方法[J]. 《计算机应用》唯一官方网站, 2023, 43(S2): 298-305. |
[9] | 李向军, 王俊洪, 王诗璐, 陈金霞, 孙纪涛, 王建辉. 基于多模型并行融合网络的恶意流量检测方法[J]. 《计算机应用》唯一官方网站, 2023, 43(S2): 122-129. |
[10] | 张涵钰, 李振波, 李蔚然, 杨普. 基于机器视觉的水产养殖计数研究综述[J]. 《计算机应用》唯一官方网站, 2023, 43(9): 2970-2982. |
[11] | 陈俊韬, 朱子奇. 基于多尺度特征提取与融合的图像复制-粘贴伪造检测[J]. 《计算机应用》唯一官方网站, 2023, 43(9): 2919-2924. |
[12] | 何子仪, 杨燕, 张熠玲. 深度融合多视图聚类网络[J]. 《计算机应用》唯一官方网站, 2023, 43(9): 2651-2656. |
[13] | 李校林, 杨松佳. 基于深度学习的多用户毫米波中继网络混合波束赋形[J]. 《计算机应用》唯一官方网站, 2023, 43(8): 2511-2516. |
[14] | 郭祥, 姜文刚, 王宇航. 基于改进Inception-ResNet的加密流量分类方法[J]. 《计算机应用》唯一官方网站, 2023, 43(8): 2471-2476. |
[15] | 崔雨萌, 王靖亚, 刘晓文, 闫尚义, 陶知众. 融合注意力和裁剪机制的通用文本分类模型[J]. 《计算机应用》唯一官方网站, 2023, 43(8): 2396-2405. |
阅读次数 | ||||||
全文 |
|
|||||
摘要 |
|
|||||