1 / 56

DCT

DCT. By : Naghmeh Karimi The material in this class presentation have been collected from different published works of other authors and are presented here for educational purposes only. Under supervision of: Dr. Fakhraie University of Tehran. Outline. Introduction JPEG coding

darin
Télécharger la présentation

DCT

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. DCT By:Naghmeh Karimi The material in this class presentation have been collected from different published works of other authors and are presented here for educational purposes only. Under supervision of: Dr. Fakhraie University of Tehran Naghmeh Karimi; Tehran University

  2. Outline • Introduction • JPEG coding • DCT technique Naghmeh Karimi; Tehran University

  3. Introduction Naghmeh Karimi; Tehran University

  4. JPEG Coding • Lossy • Lossless Naghmeh Karimi; Tehran University

  5. Lossless Compression Compressed image data Source image data Predictor Entropy Coder Entropy_Table Specifications Naghmeh Karimi; Tehran University

  6. Lossy Compression • Baseline sequential mode compression • Progressive mode • Hierarchical mode Naghmeh Karimi; Tehran University

  7. Baseline Sequential mode • An image is partitioned into some 8 by 8 non-overlapping pixel blocks from left to right and top to bottom. • Each block is coded individually. Naghmeh Karimi; Tehran University

  8. Progressive mode • Start with a low quality image and successively improve. • Spectral selection: Send DC component and first few AC coefficients first, then gradually some more ACs. 2. Successive approximation: send DCT coefficients MSB (most significant bit) to LSB (least significant bit). Naghmeh Karimi; Tehran University

  9. Hierarchical mode • Down-sample by factors of 2 in each dimension, e.g., reduce 640 x 480 to 320 x 240 2. Code smaller image using another JPEG mode (Progressive, Sequential, or Lossless) 3. Decode and up-sample encoded image 4. Encode difference between the up-sampled and the original using Progressive,Sequential, or Lossless. Naghmeh Karimi; Tehran University

  10. Hierarchical mode • An image is coded as a sequence of layers in a pyramid. • Except for the top level of pyramid, for each luminance and color component at the lower levels, the difference between the source components and the reference reconstructed image is coded. Naghmeh Karimi; Tehran University

  11. Entropy table Entropy table Qtable Down sampling Baseline JPEG Encoder(block diagram) AC VLC Zigzag Compressed image data Q Zero shift DCT VLC Diff DC image Naghmeh Karimi; Tehran University

  12. Color Transformation • The human visual systems is most sensitive to changes in luminance and less to changes in chrominance. • RGB must be converted to the other color systems . Naghmeh Karimi; Tehran University

  13. YUV system • Y = 0.299R + 0.587G + 0.114B ; • U = B - Y ; • V = R - Y ; Naghmeh Karimi; Tehran University

  14. Zero Shift • After transformation Y, U and V are in the range of [0,255] • Zero shift changes this range to [-128,127] Naghmeh Karimi; Tehran University

  15. DCT • The strength of transform coding in achieving data compression is that the image energy of the most natural scenes is mainly concentrated in the low frequency region and hence into a few transform coefficients. Naghmeh Karimi; Tehran University

  16. Quantization • Quantization allows us to reduce the accuracy with witch the DCT coefficients are represented when converting the DCT to an integer representation. • It tends to make many coefficients zero, specially those for high spatial frequencies. • Two standard table are available for quantization. Naghmeh Karimi; Tehran University

  17. Zigzag Scan • The zigzag pattern used in the JPEG algorithms orders the basis functions from low to high spatial frequencies . • It facilitate entropy coding by encountering the most likely non-zero coefficient first. Naghmeh Karimi; Tehran University

  18. Run Length Coding • For the JPEG standard, a symbol is structured in 2 parts: • Symbol1 (VLC) • Symbol2 binary representation of amplitude Naghmeh Karimi; Tehran University

  19. Coding DC Coefficients • The differential rules are categorized based on the magnitude range called “CAT”. • The “CAT” is Variable Length Coded. Naghmeh Karimi; Tehran University

  20. Coding AC Coefficients • For each non-zero AC coefficient in zigzag Scan symbol1 is described as a 2dimentional event of ( Run, Cat ). • Cat : category for the amplitude of a non-zero coefficient. • Run: the number of zeros preceding this non-zero coefficient. Naghmeh Karimi; Tehran University

  21. Coding AC Coefficients(Cont.) • If Run is greater than 15 then (Run, Cat) must be broken to some (15,0) followed by a (Cat1, Run1). • Example: (34,5) (15,0),(15,0),(2,5) • The end of the block is represented by (0,0) Naghmeh Karimi; Tehran University

  22. Improving DCT Efficiency • Using LUTs . • Using FDCT Algorithms. • Using Pipeline structures. Naghmeh Karimi; Tehran University

  23. Example A= 5  (3,3) 111111110101101 Naghmeh Karimi; Tehran University

  24. 2-DCT Naghmeh Karimi; Tehran University

  25. First_Technique • 8-point DCT and IDCT • DCT • Input :8 bit • Output:10 bit • IDCT • Input :10 bit • Output:8 bit Naghmeh Karimi; Tehran University

  26. 8-point IDCT Naghmeh Karimi; Tehran University

  27. 8-point IDCT(Cont.) Naghmeh Karimi; Tehran University

  28. Rotator Naghmeh Karimi; Tehran University

  29. Rotator • Another Architecture with 3 adder and 3 multiplier is possible. Naghmeh Karimi; Tehran University

  30. 8-point DCT Naghmeh Karimi; Tehran University

  31. Rotator Naghmeh Karimi; Tehran University

  32. Implementation Results Naghmeh Karimi; Tehran University

  33. Second_Technique Naghmeh Karimi; Tehran University

  34. 1-D IDCT Equation Coefficients Original Coefficients Simplified Coefficients Naghmeh Karimi; Tehran University

  35. Second_Technique Naghmeh Karimi; Tehran University

  36. Total_Implementation Naghmeh Karimi; Tehran University

  37. Wave-Forms Naghmeh Karimi; Tehran University

  38. Results Naghmeh Karimi; Tehran University

  39. Third_Technique(Pipeline) Naghmeh Karimi; Tehran University

  40. Pipeline stages Naghmeh Karimi; Tehran University

  41. Pipeline Structure • Each 1-D DCT stage : 8 clk cycle • 1-D DCT architecture latency : 48 clk cycle • The transpose buffer latency : 64 clk cycle • Total:160 clk cycle Naghmeh Karimi; Tehran University

  42. Fourth_Technique Naghmeh Karimi; Tehran University

  43. FDCT (cosine-factors) Naghmeh Karimi; Tehran University

  44. Data flow graph for 8 point FDCT Naghmeh Karimi; Tehran University

  45. Schematic of 2-D DCT Naghmeh Karimi; Tehran University

  46. Schematic of transposition memory Naghmeh Karimi; Tehran University

  47. Architecture and Operation of2-D DCT Circuit Reset Dout Din Clk Naghmeh Karimi; Tehran University

  48. Timing Diagram for External In/Out Port (A): Serial to Parallel conversion for input (B):1-D DCT operation (C): Parallel to Serial conversion for output Naghmeh Karimi; Tehran University

  49. Functionality of internally generated control signals Naghmeh Karimi; Tehran University

  50. Row 1-D DCT Operation Timing Diagram of Row 1-D DCT Naghmeh Karimi; Tehran University

More Related