1
|
|
2
|
|
3
|
- (tomorrow) Tuesday Night
- Feedback cancellation
- http://www.aes.org/sections/pnw/
|
4
|
- Average: 82
- High: 99, Low 59
- Distribution:
- 9 A’s
- 13 B’s
- 8 C’s
- 3 D’s
- 1 F
|
5
|
- See me if you need clarification
- Please make an appointment with me if you achieved less than a C
|
6
|
- Just what are the losses in lossy compression?
- Tools: brighten, difference
|
7
|
- At low compression ratios:
- Compressed image appears the same as original
- But at higher compression ratios:
|
8
|
- More Claude Shannon Information theory
- Determine min. amount of information R
- Should be communicated over a channel
- Such that the input signal
- Can be reconstructed at the receiver (output signal)
- Given distortion D
|
9
|
- Provides theoretical bounds for max compression achievable using lossy
techniques
- Existing lossy compression techniques’s use the general shape of
rate-distortion fn’s for:
- Transforms
- Quantization
- Bit rate allocation procedures
|
10
|
- Rate
- Number of bits per data sample
- Distortion
- Evolving definition
- Simplest:
- Variance of the difference between input and output signal
- (mean square error of differences)
- However better to incorporate models of human perception
|
11
|
- I(c,r) Original image
- I'(c,r) An approximation
- (has been compressed and decompressed)
- 0 ≤ c < M
- 0 ≤ r < N
- The error between the images at a pixel is
- e(c,r) = I'(c,r) - I(c,r)
|
12
|
|
13
|
|
14
|
- If we write I'(c,r) = e(c,r) +
I(c,r)
- We can view the reconstructed image as the original plus noise
|
15
|
|
16
|
- Joint Photographic Experts Group
- ISO standard 10918-1
- Digital Compression and Coding of Continuous-tone Still Images
- http://www.jpeg.org
|
17
|
- Many agendas:
- Corporate/Commercial
- must incorporate support for their product
- Ego
- Every participant needs to get something accepted into the std
- Consequently: standards are rarely fully implemented
|
18
|
- Subset commonly used/implemented:
- Sequential
- Progressive
- Multiple, progressively higher resolution images
- Image ‘improves’ as it downloads
- Not used
|
19
|
- JPEG specifies the compressed bytestream
- JFIF
- JPEG File Interchange Format
- Specifies packing those bytes into a file
|
20
|
- A data stream
- Made up of components separated by markers
- Markers: 2 bytes, 1st 0xFF
- (0xFF rarely occurs in JPEG data and is encoded as 0xFF 0x00)
|
21
|
- Start of image
- End of image
- Restart
- Define Huffman Table
- Define Quantization Tables
- Define restart interval
- Start of scan
- Start of frame, baseline
- Start of Frame, extended sequential
- Start of Frame, progressive
- Comment
|
22
|
- Big-endian format
- Start of Image (SOI) marker
- (1st two bytes)
- 0xFF 0xD8
- APP0 (application marker)
- Optional APP0 extension marker for thumbnails
- Tables
|
23
|
- SOF (start f frame)
- Tables
- SOS (start of scan 1)
- Scan 1 data…
- Tables
- SOS (start of scan 2)
- …
- EOI (end of image)
|
24
|
- EXIF
- Used by digital cameras
- Stores meta data
- http://exif.org
- JNG (pronounced jing)
- JPEG network graphics
- Related to PNG
- Supports transparency
|
25
|
- Compressing photographic content
- Smooth variation of tone and color
- Not good for text, line graphics, etc.
|
26
|
- JPEG is used for hi quality video
- Especially when editing is performed
- I worked on a COSMO Compress at SGI for Avid
|
27
|
- Up to 10:1
- Nearly indistinguishable results
- Up to 100:1
- Recognizable images with artifacts
|
28
|
|
29
|
|
30
|
- Really about:
- Intelligently throwing away data
|
31
|
- (Begin with 24bit RGB image)
- YUV Color Space Conversion
- Chroma Subsampling
- DCT (Discrete Cosine Transform)
- Quantization
- Entropy Coding
|
32
|
- YUV (also Y,Cb,Cr)
- Y luminance
- Cb, Cr (chomaticity)
- Same color space used in NTSC Television
- Useful because human vision is more sensitive to detail in brightness
than color
|
33
|
- ¼ resolution U, V
- (1/2 vertical ½ horizontal)
- Reduce storage requirements in half
|
34
|
- 3 part ratio
- Ex: 4:4:4
- 1st part: number of luma pixels in sample area
- 2nd part: number of chroma pixels in odd lines
- 3rd part: number of chroma pixels in even lines
- Optionally can change or elliminate subsampling
|
35
|
|
36
|
- 4:2:0
- Default
- (decimate by 2x horizontally and vertically)
- 4:2:2
- (decimate by 2x horizontally)
- 4:4:4
|
37
|
- Each YUV component of image is tiled into 8x8 blocks
- DCT is used to convert each tile into frequency space
|
38
|
- Motivation Human vision
- Good at seeing:
- Brightness differences over large areas
- Poor at distinguishing:
- Exact strength of high frequency variation
- So: We can greatly reduce information in high frequencies
|
39
|
- Each component in frequency domain
- Divided by a constant (for the component)
- Result rounded to nearest integer
- Many hi-freq components rounded to zero
- Many remaining components become small positive or negative values
|
40
|
- This is the largest lossy operation
- This stage is controlled by Q-Tables
- Q-Table selection controls the amount of compression
- By controlling the divisors per component, per frequency
|
41
|
|
42
|
- Components are zig-zag ordered
- Groups similar frequencies together
- Zeros are run length coded
- Results are Huffman coded
|
43
|
- ‘Simply’ reverse the 5 steps
|
44
|
- Old Fashioned
- Wavelet approaches achieve higher compression with better quality
- JPEG2000
- Microsoft decoder contains buffer overrun problems
- Yes: You can ‘catch’ a virus (or worse) simply by looking at an image
- Forgent Networks 2002 patent issue?
|
45
|
- Type of Fourier Transform
- Similar to DFT (discrete Fourier Transform)
- But uses only real numbers
- Basically a DFT of 2x length operating on real data with even symmetry
|
46
|
- DCT is used in JPEG because of its “energy compaction” property
- Most signal information tends to concentrate in low freq. components of
DCT
- (approaches optimal transform for certain signals)
|
47
|
|
48
|
- Can be performed by
- Doing 1D DCT on rows
- Followed by a 1D DCT on the columns
- With clever mathematical optimization
- 8x8 DCT matrix multiplication with
|
49
|
- What happens if a JPEG compressed image is re-compressed
- Perhaps at a higher compression ratio
- Or repeatedly at the same ratio
- Is additional data degraded?
|
50
|
- Does an image have to be decompressed to perform standard image
operations to?
- Crop
- Brighten
- Create histogram
|
51
|
- Are certain operations even more efficient in ‘compressed space’?
|
52
|
- How is it possible to generate optimal QTables for any given image?
|