Presentation is loading. Please wait.

Presentation is loading. Please wait.

By: Hitesh Yadav Supervising Professor: Dr. K. R. Rao Department of Electrical Engineering The University of Texas at Arlington Optimization of the Deblocking.

Similar presentations


Presentation on theme: "By: Hitesh Yadav Supervising Professor: Dr. K. R. Rao Department of Electrical Engineering The University of Texas at Arlington Optimization of the Deblocking."— Presentation transcript:

1 By: Hitesh Yadav Supervising Professor: Dr. K. R. Rao Department of Electrical Engineering The University of Texas at Arlington Optimization of the Deblocking Filter Algorithm in H.264 Codec for Real Time Implementation

2 Brief Information about H.264 H.264 is the latest video coding standard It addresses practical applications such as internet multimedia, wireless video, video conferencing etc. In terms of compression efficiency it is up by a factor of two over MPEG-2. The increase in compression efficiency comes at the expense of complexity. The resulting complexity does depend upon the profile of a standard implemented which is application dependent.

3 H.264 Encoder

4 H.264 Decoder

5 Why Deblocking Filter? At very low bit rates, coding visual artifacts are noticed in decoded frames. Prominent among them are blocking effects and ringing effects. Deblocking filter is used in the H.264 encoder and decoder to remove the blocking effects from decoded frames.

6 Causes of Blocking Effects Transform coding causes discontinuity between adjacent blocks. Severity of blocking effects is subject to the coarseness of quantization of the transform coefficients. Motion-compensated prediction also contributes to the blocking effects but mostly in mildly textured areas.

7 Regions Susceptible to Blocking effects For intra coded blocks the effect is hidden in either the more spatially active areas or smooth areas. For predictive coded blocks the effect mainly occurs in mildly textured areas. For predictive coded blocks the artifact known as false edge typically occurs for macro blocks with smoothly texture content.

8

9 Loop filtering vs. post filtering Post filters offer maximum freedom for decoder implementation as they are not normative part of the standard. Empirical tests have shown that loop filtering improves both objective and subjective quality of video streams with significant reduction in decoder complexity compared to post filter.

10 Desired Deblocking filter Smoothing artificial discontinuities between blocks. Differentiating between image edges and artificial edges. Image edges should not be smoothed as it degrades image quality. If needed, filters can be applied specific to image edges.

11 Desired deblocking filter It should remove the blocking effects without blurring the image. Its computational complexity should be low. It can be implemented in real time systems.

12 Summary on Relative Complexity POCS-based algorithm Weighted sum based algorithm Adaptive algorithms Algorithm Flow Iteratively projecting back and forth between two sets on entire picture Grading of blocks with grading matrix iterative on every pixel Iteratively classify and applying filter on every block edge. Major Operations Low-pass filtering, DCT Weighted sum of 4 pixels for each pixel 3-tap or 5-tap filter on pixels across edges Relative Computation Complexity HighMediumLow Relative Implementation Complexity HighLowMedium Visual QualityBestGood

13 Algorithm used for deblocking filter in H.264 Standard As the relative computation complexity of adaptive algorithm is low as shown in the table, they are the first choice in real time implementation. Deblocking filter uses adaptive algorithm in H.264 standard to remove the blocking effects.

14 Deblocking filter operation The deblocking filter is applied to all the edges of a 4x4 pixels block in each macroblock except to the edges on the boundary of a frame or a slice. For each block,vertical edges are filtered from left to right first, and then horizontal edges are filtered from top to bottom.

15 Main characteristics of deblocking filter On slice level, the filtering strength can be adjusted to the individual characteristics of the video sequence. On edge level, the filtering strength is dependent on inter/intra, motion and coded residuals. On pixel level, quantizer dependent threshold can turn off filtering for every individual pixel.

16 Principle of deblocking filter The decision tap for each pixel is based on the following factors. 1. Boundary strength 2. Thresholds α and β. 3. The content of sample pixels

17 Decision flow of bS where P and Q denote adjacent blocks

18 Decision flow of filter tap selection bS!=0 AND |A0-B0| <α AND |A1-A0| <β AND |B1-B0|<β

19 Problems with the Deblocking Filter Analysis of run-time profiles of decoder sub- functions reported that deblocking filter process in H.264 standard is the most computationally intensive part. Deblocking filter took as much as one-third of the computational resources of the decoder.

20 Reasons for the Complexity High adaptivity of the filter which requires conditional block edge and pixel levels. As a result, conditional branches almost inevitably appear in the innermost loops of the algorithm. Small block size employed for residual coding also contributes to high complexity. Also the code exposes little parallelism.

21 How can complexity be reduced? Some of the branches are inherited to the algorithm itself.So it is hard to eliminate them at programming level. Nothing can be done about the small block size employed for residual coding. If the conditional branches in the innermost loop of the algorithm and access to memory are reduced,complexity can be reduced.

22 Why loops add to complexity in real time? Program code includes extensive conditional branching which makes it unsuitable for deeply pipelined processors. Also the little parallelism exhibited by code makes it unsuitable for VLIW processors. VLIW processors otherwise are well suited for video encoding/decoding applications.

23 Proposed Algorithm

24 Intra Frame Results for Main Profile Test clip (QCIF) QP PSNR (dB) Reconstruction with Proposed Method Reconstruction without Loop Filter JM 9.2 (H.264 reference software) Reconstruction with Loop Filter JM 9.2 (H.264 reference software) Foreman 3731.61531.36331.637 Car phone 3731.61631.31831.620 Car phone 4526.67126.29126.612 News 3532.20432.04032.043 News 3929.51529.31329.55 Silent 3929.48929.26929.330 Container 3929.53929.38329.493 Container 4525.71825.55325.710 Bridge-close 3729.88629.73829.828 Bridge-close 4525.81625.63525.805

25 Blocking Artifacts Reconstructed I frame without using a loop filter with QP=37 Reconstructed I frame with proposed method with QP=37

26 Reconstructed I frame without using a loop filter with QP=45

27 Reconstructed I frame with proposed method with QP=45

28 Reconstructed I frame without using a loop filter with QP=37

29 Reconstructed I frame with proposed method with QP=37

30 Reconstructed I frame without using a loop filter with QP=45

31 Reconstructed I frame with proposed method with QP=45

32 Test clip (QCIF) -Type of frames QP PSNR (dB)Total number of bits used Reconstruction with Proposed Method Reconstruction without Loop filter JM 9.2 (H.264 software) Reconstruction with Loop filter JM 9.2 (H.264 software) Reconstruction with Proposed Method Reconstruction without Loop filter JM 9.2 (H.264 software) Reconstruction with Loop filter JM 9.2 (H.264 software) Foreman-P 3929.88329.83429.692208521312107 News-P 3927.84627.52827.771411940744235 Car phone-P 3930.27130.02430.171817897720 Bridge close-P 3928.48428.49528.48010552126 Foreman-B 3928.92528.87929.054489515499 News-B 3928.08528.30727.982142418021687 Car phone-B 3929.63729.43829.491197203193 Bridge close-B 3928.53228.55828.48053 P Frame and B-frame results for Main profile

33 Reconstructed P frame without using a loop filter with QP=39

34 Reconstructed P frame with proposed method with QP=39

35 Reconstructed B frame without using a loop filter with QP=39

36 Reconstructed B frame with proposed method with QP=39

37 Results for a GOP of size 10 Frame Type- frame number (Foreman _qcif) QP PSNR (dB) Reconstruction with Proposed Method Reconstruction without Loop Filter JM 9.2 (H.264 software) Reconstruction with Loop Filter JM 9.2 (H.264 software) Intra -04526.05825.85126.096 B -33928.134128.06628.044 P -83928.66828.55628.411 B -93928.26928.43928.157 P-103928.73128.72728.534

38 Advantages Memory is saved as the proposed loop filter code size is 11kb compared to JM 9.2(H.264 software) loop filter code size of 21kb. JM 9.2 uses 2 tables of size 52 bytes and one table of size 260 bytes to check the pixel filtering condition. No such tables are used in the proposed method to check the filtering condition. Hence time of the processor is saved. Conditional loops in the innermost loops of the algorithm are reduced compared to JM 9.2.

39 Further Research The proposed deblocking filter can be implemented in a DSP or VLIW processor. The deringing filter can also be incorporated to see its effects on the reconstructed video. Computationally realizable image recovery techniques can be explored in H.264. Transforms which do not produce blocking artifacts but at the same time provides the benefits of integer DCT can be explored.

40 References

41

42

43 Thank You !!


Download ppt "By: Hitesh Yadav Supervising Professor: Dr. K. R. Rao Department of Electrical Engineering The University of Texas at Arlington Optimization of the Deblocking."

Similar presentations


Ads by Google