Skip to content

Commit b32d27c

Browse files
authored
add text detection model from ppocrv3 (opencv#180)
1 parent b6e370b commit b32d27c

19 files changed

+1534
-375
lines changed

README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -95,13 +95,13 @@ Some examples are listed below. You can find more in the directory of each model
9595

9696
![qrcode](./models/qrcode_wechatqrcode/example_outputs/wechat_qrcode_demo.gif)
9797

98-
### Chinese Text detection [DB](./models/text_detection_db/)
98+
### Chinese Text detection [PPOCR-Det](./models/text_detection_ppocr/)
9999

100-
![mask](./models/text_detection_db/example_outputs/mask.jpg)
100+
![mask](./models/text_detection_ppocr/example_outputs/mask.jpg)
101101

102-
### English Text detection [DB](./models/text_detection_db/)
102+
### English Text detection [PPOCR-Det](./models/text_detection_ppocr/)
103103

104-
![gsoc](./models/text_detection_db/example_outputs/gsoc.jpg)
104+
![gsoc](./models/text_detection_ppocr/example_outputs/gsoc.jpg)
105105

106106
### Text Detection with [CRNN](./models/text_recognition_crnn/)
107107

benchmark/README.md

Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -104,6 +104,10 @@ mean median min input size model
104104
1.19 1.30 1.07 [100, 100] WeChatQRCode with ['detect_2021nov.prototxt', 'detect_2021nov.caffemodel', 'sr_2021nov.prototxt', 'sr_2021nov.caffemodel']
105105
80.97 80.06 73.20 [640, 480] DB with ['text_detection_DB_IC15_resnet18_2021sep.onnx']
106106
80.73 85.47 72.06 [640, 480] DB with ['text_detection_DB_TD500_resnet18_2021sep.onnx']
107+
23.86 24.16 23.26 [640, 480] PPOCRDet with ['text_detection_cn_ppocrv3_2023may.onnx']
108+
23.94 23.76 23.26 [640, 480] PPOCRDet with ['text_detection_en_ppocrv3_2023may.onnx']
109+
26.89 24.78 23.26 [640, 480] PPOCRDet with ['text_detection_cn_ppocrv3_2023may_int8.onnx']
110+
28.82 29.58 23.26 [640, 480] PPOCRDet with ['text_detection_en_ppocrv3_2023may_int8.onnx']
107111
17.97 16.18 12.43 [1280, 720] CRNN with ['text_recognition_CRNN_CH_2021sep.onnx']
108112
19.54 20.66 12.43 [1280, 720] CRNN with ['text_recognition_CRNN_CN_2021nov.onnx']
109113
17.73 24.25 9.65 [1280, 720] CRNN with ['text_recognition_CRNN_EN_2021sep.onnx']
@@ -159,6 +163,10 @@ mean median min input size model
159163
5.90 5.90 5.81 [100, 100] WeChatQRCode with ['detect_2021nov.prototxt', 'detect_2021nov.caffemodel', 'sr_2021nov.prototxt', 'sr_2021nov.caffemodel']
160164
2033.55 2454.13 1769.20 [640, 480] DB with ['text_detection_DB_IC15_resnet18_2021sep.onnx']
161165
1896.61 1977.38 1769.20 [640, 480] DB with ['text_detection_DB_TD500_resnet18_2021sep.onnx']
166+
462.50 463.67 456.98 [640, 480] PPOCRDet with ['text_detection_cn_ppocrv3_2023may.onnx']
167+
462.97 464.33 456.98 [640, 480] PPOCRDet with ['text_detection_en_ppocrv3_2023may.onnx']
168+
470.79 464.35 456.98 [640, 480] PPOCRDet with ['text_detection_cn_ppocrv3_2023may_int8.onnx']
169+
481.71 479.50 456.98 [640, 480] PPOCRDet with ['text_detection_en_ppocrv3_2023may_int8.onnx']
162170
237.73 237.57 236.82 [1280, 720] CRNN with ['text_recognition_CRNN_CH_2021sep.onnx']
163171
265.16 270.22 236.82 [1280, 720] CRNN with ['text_recognition_CRNN_CN_2021nov.onnx']
164172
239.69 298.68 198.88 [1280, 720] CRNN with ['text_recognition_CRNN_EN_2021sep.onnx']
@@ -215,6 +223,10 @@ mean median min input size model
215223
5.69 5.72 5.66 [100, 100] WeChatQRCode with ['detect_2021nov.prototxt', 'detect_2021nov.caffemodel', 'sr_2021nov.prototxt', 'sr_2021nov.caffemodel']
216224
1070.55 1072.14 1055.67 [640, 480] DB with ['text_detection_DB_IC15_resnet18_2021sep.onnx']
217225
1071.56 1071.38 1055.67 [640, 480] DB with ['text_detection_DB_TD500_resnet18_2021sep.onnx']
226+
238.89 238.22 236.97 [640, 480] PPOCRDet with ['text_detection_cn_ppocrv3_2023may.onnx']
227+
238.41 240.39 236.97 [640, 480] PPOCRDet with ['text_detection_en_ppocrv3_2023may.onnx']
228+
276.96 240.19 236.97 [640, 480] PPOCRDet with ['text_detection_cn_ppocrv3_2023may_int8.onnx']
229+
304.04 311.21 236.97 [640, 480] PPOCRDet with ['text_detection_en_ppocrv3_2023may_int8.onnx']
218230
258.11 258.13 257.64 [1280, 720] CRNN with ['text_recognition_CRNN_CH_2021sep.onnx']
219231
275.27 277.20 257.64 [1280, 720] CRNN with ['text_recognition_CRNN_CN_2021nov.onnx']
220232
254.90 295.88 221.12 [1280, 720] CRNN with ['text_recognition_CRNN_EN_2021sep.onnx']
@@ -251,6 +263,10 @@ mean median min input size model
251263
91.40 92.74 89.76 [256, 256] MPPose with ['pose_estimation_mediapipe_2023mar.onnx']
252264
223.24 224.30 216.37 [640, 480] DB with ['text_detection_DB_IC15_resnet18_2021sep.onnx']
253265
223.03 222.28 216.37 [640, 480] DB with ['text_detection_DB_TD500_resnet18_2021sep.onnx']
266+
112.35 111.90 109.99 [640, 480] PPOCRDet with ['text_detection_cn_ppocrv3_2023may.onnx']
267+
112.68 114.63 109.93 [640, 480] PPOCRDet with ['text_detection_en_ppocrv3_2023may.onnx']
268+
183.96 112.72 109.93 [640, 480] PPOCRDet with ['text_detection_cn_ppocrv3_2023may_int8.onnx']
269+
234.57 249.45 109.93 [640, 480] PPOCRDet with ['text_detection_en_ppocrv3_2023may_int8.onnx']
254270
44.24 45.21 41.87 [1280, 720] CRNN with ['text_recognition_CRNN_CH_2021sep.onnx']
255271
45.15 44.15 41.87 [1280, 720] CRNN with ['text_recognition_CRNN_CN_2021nov.onnx']
256272
36.82 46.54 21.75 [1280, 720] CRNN with ['text_recognition_CRNN_EN_2021sep.onnx']
@@ -282,6 +298,10 @@ mean median min input size model
282298
91.28 92.89 89.79 [256, 256] MPPose with ['pose_estimation_mediapipe_2023mar.onnx']
283299
254.78 256.13 245.60 [640, 480] DB with ['text_detection_DB_IC15_resnet18_2021sep.onnx']
284300
254.98 255.20 245.60 [640, 480] DB with ['text_detection_DB_TD500_resnet18_2021sep.onnx']
301+
427.53 428.67 425.63 [640, 480] PPOCRDet with ['text_detection_cn_ppocrv3_2023may.onnx']
302+
427.79 429.28 425.63 [640, 480] PPOCRDet with ['text_detection_en_ppocrv3_2023may.onnx']
303+
414.07 429.46 387.26 [640, 480] PPOCRDet with ['text_detection_cn_ppocrv3_2023may_int8.onnx']
304+
406.10 407.83 383.41 [640, 480] PPOCRDet with ['text_detection_en_ppocrv3_2023may_int8.onnx']
285305
33.07 32.88 32.00 [1280, 720] CRNN with ['text_recognition_CRNN_CH_2021sep.onnx']
286306
33.88 33.64 32.00 [1280, 720] CRNN with ['text_recognition_CRNN_CN_2021nov.onnx']
287307
29.32 33.70 20.69 [1280, 720] CRNN with ['text_recognition_CRNN_EN_2021sep.onnx']
@@ -332,6 +352,10 @@ mean median min input size model
332352
127.16 173.93 99.77 [256, 256] MPPose with ['pose_estimation_mediapipe_2023mar.onnx']
333353
975.49 977.45 952.43 [640, 480] DB with ['text_detection_DB_IC15_resnet18_2021sep.onnx']
334354
970.16 970.83 928.66 [640, 480] DB with ['text_detection_DB_TD500_resnet18_2021sep.onnx']
355+
238.38 241.90 233.21 [640, 480] PPOCRDet with ['text_detection_cn_ppocrv3_2023may.onnx']
356+
238.05 236.53 232.05 [640, 480] PPOCRDet with ['text_detection_en_ppocrv3_2023may.onnx']
357+
262.58 238.47 232.05 [640, 480] PPOCRDet with ['text_detection_cn_ppocrv3_2023may_int8.onnx']
358+
280.63 279.26 232.05 [640, 480] PPOCRDet with ['text_detection_en_ppocrv3_2023may_int8.onnx']
335359
194.80 195.37 192.65 [1280, 720] CRNN with ['text_recognition_CRNN_CH_2021sep.onnx']
336360
209.49 208.33 192.65 [1280, 720] CRNN with ['text_recognition_CRNN_CN_2021nov.onnx']
337361
192.90 227.02 161.94 [1280, 720] CRNN with ['text_recognition_CRNN_EN_2021sep.onnx']
@@ -363,6 +387,8 @@ mean median min input size model
363387
379.46 366.19 360.02 [640, 640] YoloX with ['object_detection_yolox_2022nov_int8.onnx']
364388
33.90 36.32 31.71 [192, 192] MPPalmDet with ['palm_detection_mediapipe_2023feb_int8.onnx']
365389
40.34 41.50 38.47 [128, 256] YoutuReID with ['person_reid_youtu_2021nov_int8.onnx']
390+
162.54 162.78 155.24 [640, 480] PPOCRDet with ['text_detection_cn_ppocrv3_2023may_int8.onnx']
391+
161.50 160.70 147.69 [640, 480] PPOCRDet with ['text_detection_en_ppocrv3_2023may_int8.onnx']
366392
239.68 239.31 236.03 [1280, 720] CRNN with ['text_recognition_CRNN_CH_2022oct_int8.onnx']
367393
199.42 203.20 166.15 [1280, 720] CRNN with ['text_recognition_CRNN_CN_2021nov_int8.onnx']
368394
197.49 169.51 166.15 [1280, 720] CRNN with ['text_recognition_CRNN_EN_2022oct_int8.onnx']
@@ -413,6 +439,10 @@ mean median min input size model
413439
134.02 136.01 132.06 [256, 256] MPPose with ['pose_estimation_mediapipe_2023mar.onnx']
414440
1441.73 1442.80 1440.26 [640, 480] DB with ['text_detection_DB_IC15_resnet18_2021sep.onnx']
415441
1436.45 1437.89 1430.58 [640, 480] DB with ['text_detection_DB_TD500_resnet18_2021sep.onnx']
442+
360.26 360.82 359.13 [640, 480] PPOCRDet with ['text_detection_cn_ppocrv3_2023may.onnx']
443+
361.22 361.51 359.13 [640, 480] PPOCRDet with ['text_detection_en_ppocrv3_2023may.onnx']
444+
427.85 362.87 359.13 [640, 480] PPOCRDet with ['text_detection_cn_ppocrv3_2023may_int8.onnx']
445+
475.44 490.06 359.13 [640, 480] PPOCRDet with ['text_detection_en_ppocrv3_2023may_int8.onnx']
416446
285.19 284.91 284.69 [1280, 720] CRNN with ['text_recognition_CRNN_CH_2021sep.onnx']
417447
318.96 323.30 284.69 [1280, 720] CRNN with ['text_recognition_CRNN_CN_2021nov.onnx']
418448
289.82 360.87 244.07 [1280, 720] CRNN with ['text_recognition_CRNN_EN_2021sep.onnx']
@@ -496,6 +526,10 @@ mean median min input size model
496526
790.98 823.19 755.99 [256, 256] MPPose with ['pose_estimation_mediapipe_2023mar.onnx']
497527
49331.32 49285.30 49210.67 [640, 480] DB with ['text_detection_DB_IC15_resnet18_2021sep.onnx']
498528
49327.34 49489.22 49210.67 [640, 480] DB with ['text_detection_DB_TD500_resnet18_2021sep.onnx']
529+
4422.65 4432.92 4376.19 [640, 480] PPOCRDet with ['text_detection_cn_ppocrv3_2023may.onnx']
530+
4407.88 4405.92 4353.22 [640, 480] PPOCRDet with ['text_detection_en_ppocrv3_2023may.onnx']
531+
3782.89 4404.01 2682.63 [640, 480] PPOCRDet with ['text_detection_cn_ppocrv3_2023may_int8.onnx']
532+
3472.93 3557.78 2682.63 [640, 480] PPOCRDet with ['text_detection_en_ppocrv3_2023may_int8.onnx']
499533
2183.70 2172.36 2156.29 [1280, 720] CRNN with ['text_recognition_CRNN_CH_2021sep.onnx']
500534
2225.19 2222.58 2156.29 [1280, 720] CRNN with ['text_recognition_CRNN_CN_2021nov.onnx']
501535
2214.03 2302.61 2156.29 [1280, 720] CRNN with ['text_recognition_CRNN_EN_2021sep.onnx']
@@ -552,6 +586,10 @@ mean median min input size model
552586
41.26 42.74 40.08 [256, 256] MPPose with ['pose_estimation_mediapipe_2023mar.onnx']
553587
384.47 401.25 360.71 [640, 480] DB with ['text_detection_DB_IC15_resnet18_2021sep.onnx']
554588
377.91 381.15 336.30 [640, 480] DB with ['text_detection_DB_TD500_resnet18_2021sep.onnx']
589+
110.51 111.04 107.73 [640, 480] PPOCRDet with ['text_detection_cn_ppocrv3_2023may.onnx']
590+
110.67 111.54 107.73 [640, 480] PPOCRDet with ['text_detection_en_ppocrv3_2023may.onnx']
591+
131.52 111.76 107.73 [640, 480] PPOCRDet with ['text_detection_cn_ppocrv3_2023may_int8.onnx']
592+
146.42 149.47 107.73 [640, 480] PPOCRDet with ['text_detection_en_ppocrv3_2023may_int8.onnx']
555593
68.70 68.63 68.54 [1280, 720] CRNN with ['text_recognition_CRNN_CH_2021sep.onnx']
556594
78.17 80.48 68.54 [1280, 720] CRNN with ['text_recognition_CRNN_CN_2021nov.onnx']
557595
71.42 91.44 61.14 [1280, 720] CRNN with ['text_recognition_CRNN_EN_2021sep.onnx']
@@ -608,6 +646,10 @@ mean median min input size model
608646
9.93 9.97 9.82 [100, 100] WeChatQRCode with ['detect_2021nov.prototxt', 'detect_2021nov.caffemodel', 'sr_2021nov.prototxt', 'sr_2021nov.caffemodel']
609647
1914.15 1913.70 1902.25 [640, 480] DB with ['text_detection_DB_IC15_resnet18_2021sep.onnx']
610648
1920.07 1929.80 1902.25 [640, 480] DB with ['text_detection_DB_TD500_resnet18_2021sep.onnx']
649+
495.04 493.75 489.41 [640, 480] PPOCRDet with ['text_detection_cn_ppocrv3_2023may.onnx']
650+
493.63 491.89 489.41 [640, 480] PPOCRDet with ['text_detection_en_ppocrv3_2023may.onnx']
651+
598.94 496.42 489.41 [640, 480] PPOCRDet with ['text_detection_cn_ppocrv3_2023may_int8.onnx']
652+
667.75 683.91 489.41 [640, 480] PPOCRDet with ['text_detection_en_ppocrv3_2023may_int8.onnx']
611653
439.96 441.91 436.49 [1280, 720] CRNN with ['text_recognition_CRNN_CH_2021sep.onnx']
612654
465.56 466.86 436.49 [1280, 720] CRNN with ['text_recognition_CRNN_CN_2021nov.onnx']
613655
431.93 495.94 373.61 [1280, 720] CRNN with ['text_recognition_CRNN_EN_2021sep.onnx']
@@ -664,6 +706,10 @@ mean median min input size model
664706
1113.51 1124.83 1106.81 [256, 256] MPPose with ['pose_estimation_mediapipe_2023mar.onnx']
665707
66015.47 65997.60 65993.81 [640, 480] DB with ['text_detection_DB_IC15_resnet18_2021sep.onnx']
666708
66023.14 66034.99 65993.81 [640, 480] DB with ['text_detection_DB_TD500_resnet18_2021sep.onnx']
709+
6094.40 6093.77 6091.85 [640, 480] PPOCRDet with ['text_detection_cn_ppocrv3_2023may.onnx']
710+
6073.33 6076.77 6055.13 [640, 480] PPOCRDet with ['text_detection_en_ppocrv3_2023may.onnx']
711+
5547.32 6057.15 4653.05 [640, 480] PPOCRDet with ['text_detection_cn_ppocrv3_2023may_int8.onnx']
712+
5284.79 5356.47 4653.05 [640, 480] PPOCRDet with ['text_detection_en_ppocrv3_2023may_int8.onnx']
667713
3230.93 3228.61 3228.29 [1280, 720] CRNN with ['text_recognition_CRNN_CH_2021sep.onnx']
668714
3312.02 3323.17 3228.29 [1280, 720] CRNN with ['text_recognition_CRNN_CN_2021nov.onnx']
669715
3262.32 3413.03 3182.11 [1280, 720] CRNN with ['text_recognition_CRNN_EN_2021sep.onnx']
@@ -719,6 +765,10 @@ mean median min input size model
719765
548.41 550.86 546.09 [256, 256] MPPose with ['pose_estimation_mediapipe_2023mar.onnx']
720766
34074.19 34077.97 34058.43 [640, 480] DB with ['text_detection_DB_IC15_resnet18_2021sep.onnx']
721767
34073.67 34069.82 34054.29 [640, 480] DB with ['text_detection_DB_TD500_resnet18_2021sep.onnx']
768+
3031.81 3031.79 3030.41 [640, 480] PPOCRDet with ['text_detection_cn_ppocrv3_2023may.onnx']
769+
3031.41 3031.17 3029.99 [640, 480] PPOCRDet with ['text_detection_en_ppocrv3_2023may.onnx']
770+
2638.47 3031.01 1969.10 [640, 480] PPOCRDet with ['text_detection_cn_ppocrv3_2023may_int8.onnx']
771+
2446.99 2500.65 1967.72 [640, 480] PPOCRDet with ['text_detection_en_ppocrv3_2023may_int8.onnx']
722772
1397.09 1396.95 1396.74 [1280, 720] CRNN with ['text_recognition_CRNN_CH_2021sep.onnx']
723773
1428.65 1432.59 1396.74 [1280, 720] CRNN with ['text_recognition_CRNN_CN_2021nov.onnx']
724774
1429.56 1467.34 1396.74 [1280, 720] CRNN with ['text_recognition_CRNN_EN_2021sep.onnx']

0 commit comments

Comments
 (0)