Top Banner
Electrical Engineering Department of National Cheng Kung University Smart Media & Intelligent Living Excellence Lab. 1 2012/08/14 指指指指 指指指指指 指指指 指指指 指指 指指 DEMO DEMO line segment line segment GPU GPU 指指 指指
28

期末 DEMO line segment 的 GPU 實現

Jan 25, 2016

Download

Documents

naida

期末 DEMO line segment 的 GPU 實現. 2012/08/14 指導教授:詹寶珠教授 報告者:陳正旻. Outline. 演算法流程介紹 ( 附實作結果 ) 時間比較和加速倍數 實作影片 總結. Flow chart. Algorithm. Line segment construction Two rules Color difference : Spatial distance :. (TIME)Line segment construction. Flow chart. Algorithm. Left. Right. - PowerPoint PPT Presentation
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: 期末 DEMO  line segment 的 GPU 實現

Electrical Engineering Department of National Cheng Kung University

Smart Media & Intelligent Living Excellence Lab. 1

2012/08/14指導教授:詹寶珠教授

報告者:陳正旻

期末期末 DEMO DEMO line segmentline segment 的的 GPUGPU 實現實現

Page 2: 期末 DEMO  line segment 的 GPU 實現

Electrical Engineering Department of National Cheng Kung University

Smart Media & Intelligent Living Excellence Lab. 2

OutlineOutline

演算法流程介紹 ( 附實作結果 )

時間比較和加速倍數實作影片總結

Page 3: 期末 DEMO  line segment 的 GPU 實現

Electrical Engineering Department of National Cheng Kung University

Smart Media & Intelligent Living Excellence Lab.

Flow chartFlow chart

3

Page 4: 期末 DEMO  line segment 的 GPU 實現

Electrical Engineering Department of National Cheng Kung University

Smart Media & Intelligent Living Excellence Lab.

AlgorithmAlgorithm

Line segment construction

Two rules• Color difference :

• Spatial distance :

4

Page 5: 期末 DEMO  line segment 的 GPU 實現

Electrical Engineering Department of National Cheng Kung University

Smart Media & Intelligent Living Excellence Lab.

(TIME)Line segment construction(TIME)Line segment construction

5

Page 6: 期末 DEMO  line segment 的 GPU 實現

Electrical Engineering Department of National Cheng Kung University

Smart Media & Intelligent Living Excellence Lab.

Flow chartFlow chart

6

Page 7: 期末 DEMO  line segment 的 GPU 實現

Electrical Engineering Department of National Cheng Kung University

Smart Media & Intelligent Living Excellence Lab.

AlgorithmAlgorithm

Initial Disparity Computation

Matching cost :

• CAD :

• CCENSUS : Hamming distance of the two strings that stand for p and pd

7

String

R. Zabih and J. Woodfill, “Non-parametric local transforms for computing visual correspondence,” in Proc. ECCV, 1994, pp. 151–158.

d=1Left Right

2

Page 8: 期末 DEMO  line segment 的 GPU 實現

Electrical Engineering Department of National Cheng Kung University

Smart Media & Intelligent Living Excellence Lab.

(TIME)Initial Disparity Computation(TIME)Initial Disparity Computation& Matching cost& Matching cost

8

Page 9: 期末 DEMO  line segment 的 GPU 實現

Electrical Engineering Department of National Cheng Kung University

Smart Media & Intelligent Living Excellence Lab.

AlgorithmAlgorithm

Cost aggregation

Winner-take-all

9d=1

Left Right

Page 10: 期末 DEMO  line segment 的 GPU 實現

Electrical Engineering Department of National Cheng Kung University

Smart Media & Intelligent Living Excellence Lab.

(TIME)Cost aggregation(TIME)Cost aggregation& Winner-take-all& Winner-take-all

10

Page 11: 期末 DEMO  line segment 的 GPU 實現

Electrical Engineering Department of National Cheng Kung University

Smart Media & Intelligent Living Excellence Lab.

初步結果初步結果

左圖的 Depth 右圖的 Depth

11

Page 12: 期末 DEMO  line segment 的 GPU 實現

Electrical Engineering Department of National Cheng Kung University

Smart Media & Intelligent Living Excellence Lab.

Flow chartFlow chart

12

Page 13: 期末 DEMO  line segment 的 GPU 實現

Electrical Engineering Department of National Cheng Kung University

Smart Media & Intelligent Living Excellence Lab.

AlgorithmAlgorithm

Seed Pixel Detection

Two rules

13

Page 14: 期末 DEMO  line segment 的 GPU 實現

Electrical Engineering Department of National Cheng Kung University

Smart Media & Intelligent Living Excellence Lab.

(TIME)Seed Pixel Detection(TIME)Seed Pixel Detection

14

Page 15: 期末 DEMO  line segment 的 GPU 實現

Electrical Engineering Department of National Cheng Kung University

Smart Media & Intelligent Living Excellence Lab.

Flow chartFlow chart

15

Page 16: 期末 DEMO  line segment 的 GPU 實現

Electrical Engineering Department of National Cheng Kung University

Smart Media & Intelligent Living Excellence Lab.

AlgorithmAlgorithm

Scanline Propagation

• Aa , if p is in occluded regions.

• d

• Ss , if p is near depth discontinuities.

• a

• is replaced by the linearly interpolated results of and in all other conditions.

16

Page 17: 期末 DEMO  line segment 的 GPU 實現

Electrical Engineering Department of National Cheng Kung University

Smart Media & Intelligent Living Excellence Lab.

(TIME)Scanline Propagation(TIME)Scanline Propagation

17

Page 18: 期末 DEMO  line segment 的 GPU 實現

Electrical Engineering Department of National Cheng Kung University

Smart Media & Intelligent Living Excellence Lab.

Scanline PropagationScanline Propagation 之後的結果之後的結果

18

Page 19: 期末 DEMO  line segment 的 GPU 實現

Electrical Engineering Department of National Cheng Kung University

Smart Media & Intelligent Living Excellence Lab.

Flow chartFlow chart

19

Page 20: 期末 DEMO  line segment 的 GPU 實現

Electrical Engineering Department of National Cheng Kung University

Smart Media & Intelligent Living Excellence Lab.

AlgorithmAlgorithm

Disparity Refinement• Vertical voting : We collect 𝑁 disparity votes in a vertical

line segment that starts at pixel and ends at pixel

,if the color difference is smaller than the threshold value 𝜏 , the votes on disparity increase by 1.

• c

20

Page 21: 期末 DEMO  line segment 的 GPU 實現

Electrical Engineering Department of National Cheng Kung University

Smart Media & Intelligent Living Excellence Lab.

(TIME)Vertical voting(TIME)Vertical voting

21

Page 22: 期末 DEMO  line segment 的 GPU 實現

Electrical Engineering Department of National Cheng Kung University

Smart Media & Intelligent Living Excellence Lab.

Vertical votingVertical voting 之後的結果之後的結果

22

Page 23: 期末 DEMO  line segment 的 GPU 實現

Electrical Engineering Department of National Cheng Kung University

Smart Media & Intelligent Living Excellence Lab.

再加入再加入 BilateralFilterBilateralFilter 之後的最終結果之後的最終結果

23

Page 24: 期末 DEMO  line segment 的 GPU 實現

Electrical Engineering Department of National Cheng Kung University

Smart Media & Intelligent Living Excellence Lab.

GPU 運算時間

CPU 運算時間

24

Page 25: 期末 DEMO  line segment 的 GPU 實現

Electrical Engineering Department of National Cheng Kung University

Smart Media & Intelligent Living Excellence Lab.

時間比較和加速倍數時間比較和加速倍數LineSegment

漢明距離 單點 cost 總 cost

CPU 0.114000 (S) 0.481999 0.973999 0.352999

GPU 0.002498 (S) 0.004868 0.091873 0.016956

加速 約 45 ( 倍 ) 約 99 ( 倍 ) 約 11 ( 倍 ) 約 21 ( 倍 )

25

Seedpixel

ScanLine

Verticalvoting

DBF GPU 總時間

0.020000 0.017000 0.098000 2.059997

0.000033 0.000239 0.002314 0.002 0.120781

約 606 ( 倍 ) 約 71 ( 倍 ) 約 42 ( 倍 ) 約 18 ( 倍 )

Page 26: 期末 DEMO  line segment 的 GPU 實現

Electrical Engineering Department of National Cheng Kung University

Smart Media & Intelligent Living Excellence Lab.

實作影片實作影片

26

Page 27: 期末 DEMO  line segment 的 GPU 實現

Electrical Engineering Department of National Cheng Kung University

Smart Media & Intelligent Living Excellence Lab.

總結總結

GPU 加速持續改進。再加入各種不同方法使結果更好。

27

Page 28: 期末 DEMO  line segment 的 GPU 實現

Electrical Engineering Department of National Cheng Kung University

Smart Media & Intelligent Living Excellence Lab.

Thank for your attention!

28