腾讯云 赵军 FFmpeg 硬件加速

CodeWarrior

2019/07/08 发布于 编程 分类

GIAC2019 

文字内容
1. 66V NP
3. Wa c k ü ü ü ü ü k 66V NP VJRW JRWN k k p 66V NP k RW ;N WNU
4. ++FI AU gs e.GL E Ut r
5. k ü k ü o o s ü r O 2 O g o 66V NP v v y k k66V NP o
6. dO ü T &3. GRWMX_ . 4HF1 4HF1 • VJL?C R?C. FRMNXDXXUKX • ü gs • • ü 2 S d RW NMRJ 6X WMJ RXW . F1 1 9 F4 1E F) 1WM XRM. T NMRJ3XMNL g • 7 E. 1 4 1 6 RMRJ • CX3. 2B3 BRLTLQR F E • 6 71lHRURW 1U N J 9W NU g T gs 1 nU&3. • 3E41 • ? NW3 ? NW7 F UTJW F 3 F4 3 9W NU g C4; 1B g
7. u f e NVJ N X RVRbJ RXW R ++FI A hu ü ü 3 k V Q NJM l C9 4 ü ü 3 ü ü ü hu 4XWJUM ;W Qf p XORURWP gi QN XX XO JUU N RU kC9 4k3JLQN x j P i6 JVN CURLNjk6RU N CURLN k xm hu p3E41 ? NW7 z F UTJW /7 E ? NW3 )
8. hu ü l R g Us NMRJ ü k 3XMNL ü p ü 0 ü ü (4 JLLNUN J RXW C Um p 1F6RU N • F 1F6RU N • ? NW3 3E41 F UTJW ? NW7 ü NMRJ JWJUa RL ü ?C 8G s 1F6RU N 1 9 1F6RU N m m
9. CA 3C LM
10. ++FI A ++FI A Ø Ø Ø Ø 3 :& s E NCLB .GL E 3 P 66V NP ACF U PRW J N KJ NM XW NMRJC4;/ R QJ _RMNUa JLLN NM Ka L XVN JMMNM J J ORU N F11 9 R UX_N UN NU 1 9/ 66V NP F11 9 U PRW X RMN VX N OUN RKUN XU RXW OX L XVN 9W NP J N ( M J a ?3 ? NW3F F UTJW RMNX XLN RWP RK J a X NW RLQ QN XU RXW 66V NP U PRW _R Q 8G JLLNUN J RXW _RUU NNM MN NUX VNW OX MROON NW JPN
11. ++FI A 3 B ü ü s 1F6RU N & +./ x0 ü ü • • • ü ü ü +/& i X_ v s V ü .0 s /. k k & o y k +V s n P RW RW RL RWURWN J NVKUa QJWM _ R NW J NVKUa 66V NP WJ V aJ V ) UVNJW s vw _Qa0 , RWL J V
12. f W&. Crop, Object Object Object Scale, Tracking Tracking Tracking CSC Full resolution Decode Scale, CSC Object Detection ROI coordinates Object Object Object Object Tracking Tracking Tracking Tracking • Up to 30fps • Up to 4K • Typically FHD/HD • Mostly H.264 • HEVC demand on the rise • Input could be raw video • Scale to match NN input res. • CSC to planar RGB/BGR • Optional Crop (e.g. 1 camera across multiple lanes) • E.g. SSD/Yolo/YoloTi ny • Potentially dozens of objects/frame • Usually every Nth frame (1 < N < 6) • Worst-case N=1 • Optional • Kalman Filters • CAMShift Store meta data Object Object Object Object Tracking Tracking Tracking Classification Composi tion Display Encode Full resolution • Multiple instances • Several per detected object (or subset of) • Crop ROI coordinates • Scale to NN input resolution • CSC to planar RGB/BGR • ResNet, FaceNet, DenseNet, GoogLeNet • E.g. Vehicle type/brand/model • Optional • Draw bounding box(es), text • • • • Optional H.264 today HEVC needed Further VQ loss not acceptable
13. sS&. ++FI A &3. FIE LCE ü 1 • • ü 0/ 66V NP 0/ v4NLXMN WLXMN 6RU N & +CEL 66V NP XXU • • E NJVy • RWON NWLN XKSNL LUJ RORLJ RXW! X N UJagg
14. U W ü .G G w ü • 66V NP • s CEL 11 .G 4 4 1 9 Q G kw &3.Q C N BN XU RXW ORU N
15. 2I G
16. e2NOX N 9 K RU J _JUU 9dM J T X TWX_ GQJ 9 _J _JUURWP RW X _JUURWP X ! 1WM _QXV 9 _J URTN X PR N XOONW N CXVN QRWP QN N R QJ MXN Wd UX N J _JUU! DQJ _JW R MX_W f cBXKN U S 6 X ! e NWMRWP GJUUf P ü 66V NP 1 9 ü ? NW3F ( ü 4NN NJ WRWP JV UN 66V NP u 66V NP 66V NP x 1F6RU N m3 y 3 s m 1 9 w m
17. HGL ü 3 U 3 ü 3 U 3 Ø _ 3 E 7 Ep ü VJ üCC ) 1FH g ü7 E 3X a ü? NW3 CF 7 E Ø2 OON CQJ RWP Q . ___ TQ XWX X P NPR P Q 3 E o a ? NW3 N NW RXW RW NU LUIRW NUI JIJ RIVNMRJI QJ RW . ___ O NNMN T X X P _RTR CXO _J N 2NRPWN QX_ X URK J K OON QJ RWP QX_ X
18. B GD ü ++FI A J T DQXV XW C N NW R BX R UJ NQUR JWX ü XVVaUR U NUR k t k
19. 4 & 0H 4M LCHG Q Ø E N QN CX LN! Ø C X _X aRWP JWM MRM R JWa_Ja Ok TN
20. 2JLT
21. .GL E 3 g l
22. .GL E 3 • 3 6H 66 H U G H ++ 8 3 C63 • M – – • • – : 8 3 6H 66 F4 F3 & MNLXMRWP ? 1F3 ORNUM MX_W JV URWP + 1F3 O JVN MX_W JV URWP E F ++ – 7 F , 8 F3 QNJMN J RWP RW 8 3 8G4B QNJMN MNL a RXW RW 8 3 ++ ++ 7 ++ – – E • 3 1F3 – 0 • – – 3 • : M – – • – 7 WLXMN XW 7NW+ ++ 1F3 7 NWLXMN XW 7NW+ 8 F3 NWLXMN XW 7NW- 1 1F3 F4 3 NWLXMN XW 7NW8 F3 F - F4 3 NWLXMN XW 7NW&& M 1 8 F3 ,K & K XW 8CG 24G C;
23. .0 hu Alignment is another issue ü ü o y h N X WNXW h WNXW X N ü C9 4 h JMMRWP! NMRLJ RXW! 6JUUKJLT invalid pixels ü h NMRLJ RXW! 6JUUKJLT X LJUJ if( pix < A ){ ... üo ? C9 4 h 4R R RXW! 8RPQ UN NU O WL RXW NP. VJ Q O WL RXW ü 6UXJ RWP XRW h EW X NM L X } else if( pix >= A && pix < B){ ... } else if( pix >= B && pix < C){ ... } else if( pix >= C){ ... MNR LN 3XV J RKURU a }