Computer Science

Compression

Compression is the process of reducing the size of data to save storage space or transmission time. It is achieved by encoding information using fewer bits than the original representation. There are two main types of compression: lossless, which retains all the original data, and lossy, which sacrifices some data to achieve higher compression ratios.

Written by Perlego with AI-assistance

8 Key excerpts on "Compression"

Index pages curate the most relevant extracts from our library of academic textbooks. They’ve been created using an in-house natural language model (NLM), each adding context and meaning to key research topics.
  • How Video Works
    eBook - ePub

    How Video Works

    From Broadcast to the Cloud

    • Diana Weynand, Vance Piccin(Authors)
    • 2015(Publication Date)
    • Routledge
      (Publisher)

    ...14 Compression Compression is the process of reducing data in a digital signal by eliminating redundant information. This process reduces the amount of bandwidth required to transmit the data and the amount of storage space required to store it. Any type of digital data can be compressed. Reducing the required bandwidth permits more data to be transmitted at one time. Compression can be divided into two categories: lossless and lossy. In lossless Compression, the restored image is an exact duplicate of the original with no loss of data. In lossy Compression, the restored image is an approximation, not an exact duplicate, of the original (Figure 14.1). Lossless Compression In lossless Compression, the original data can be perfectly reconstructed from the compressed data that was contained in the original image. Compressing a document is a form of lossless Compression in that the restored document must be exactly the same as the original. It cannot be an approximation. In the visual world, lossless Compression lends itself to images that contain large quantities of repeated information, such as an image that contains a large area of one color, perhaps a blue sky. Computer-generated images or flat colored areas that do not contain much detail—e.g., cartoons, graphics, and 3D animation—also lend themselves to lossless Compression. Figure 14.1 Lossless vs Lossy Compression One type of lossless Compression commonly used in graphics and computer-generated images (CGI) is run-length encoding. These images tend to have large portions using the same colors or repeated patterns. Every pixel in a digital image is composed of the three component colors—red, green, and blue—and every pixel has a specific value for each color...

  • Compression for Great Video and Audio
    eBook - ePub

    Compression for Great Video and Audio

    Master Tips and Common Sense

    • Ben Waggoner(Author)
    • 2013(Publication Date)
    • Routledge
      (Publisher)

    ...Compression is sometimes called “entropy coding,” since what you’re really saving is the entropy (randomness) in the data, while the stuff that could be predicted from that entropy is what gets compressed away to be reconstructed on decode. The More Efficient the Coding, the More Random the Output Using a codebook makes the file smaller by reducing redundancy. Because there is less redundancy, there is by definition less of a pattern to the data itself, and hence the data itself looks random. You can look at the first few dozen characters of a text file, and immediately see what language it’s in. Look at the first few dozen characters of a compressed file, and you’ll have no idea what it is. Data Compression Data Compression is Compression that works on arbitrary content, like computer files, without having to know much in advance about their contents. There have been many different Compression algorithms used over the past few decades. Ones that are currently available use different techniques, but they share similar properties. The most-used data Compression technique is Deflate, which originated in PKWare’s.zip format and is also used in.gz files,.msi installers, http header Compression, and many, many other places. Deflate was even used in writing this book—Microsoft Word’s.docx format (along with all Microsoft Office “.???x” formats) is really a directory of files that are then Deflated into a single file. For example, the longest chapter in my current draft (“Production, Post, and Acquisition”) is 78,811 bytes. Using Deflate, it goes down to 28,869 bytes. And if I use an advanced texttuned compressor like PPMd, (included in the popular 7-Zip tool), it can get down to 22,883 bytes. But that’s getting pretty close to the theoretical lower limit for how much this kind of content can be compressed...

  • Art of Digital Audio
    • John Watkinson(Author)
    • 2013(Publication Date)
    • Routledge
      (Publisher)

    ...5 Compression 5.1 Introduction Compression, bit rate reduction and data reduction are all terms which mean basically the same thing in this context. In essence the same (or nearly the same) audio information is carried using a smaller quantity or rate of data. It should be pointed out that in audio, Compression traditionally means a process in which the dynamic range of the sound is reduced, typically by broadcasters wishing their station to sound louder. However, when bit rate reduction is employed, the dynamics of the decoded signal are unchanged. Provided the context is clear, the two meanings can co-exist without a great deal of confusion. There are several reasons why Compression techniques are popular: (a) Compression extends the playing time of a given storage device. (b) Compression allows miniaturization. With fewer data to store, the same playing time is obtained with smaller hardware. This is useful in portable and consumer devices. (c) Tolerances can be relaxed. With fewer data to record, storage density can be reduced, making equipment which is more resistant to adverse environments and which requires less maintenance. (d) In transmission systems, Compression allows a reduction in bandwidth which will generally result in a reduction in cost. This may make possible some process which would be uneconomic without it. (e) If a given bandwidth is available to an uncompressed signal, Compression allows faster than real-time transmission within that bandwidth. (f) If a given bandwidth is available, Compression allows a better-quality signal within that bandwidth. Figure 5.1 In (a) a Compression system consists of compressor or coder, a transmission channel and a matching expander or decoder. The combination of coder and decoder is known as a codec. (b) MPEG is asymmetrical since the encoder is much more complex than the decoder. Compression is summarized in Figure 5.1. It will be seen in (a) that the PCM audio data rate is reduced at source by the compressor...

  • Introduction to Digital Audio
    • John Watkinson(Author)
    • 2013(Publication Date)
    • Routledge
      (Publisher)

    ...5 Compression 5.1 Introduction Compression, bit rate reduction and data reduction are all terms which mean basically the same thing in this context. In essence the same (or nearly the same) audio information is carried using a smaller quantity and/or rate of data. It should be pointed out that in audio Compression traditionally means a process in which the dynamic range of the sound is reduced, typically by broadcasters wishing their station to sound louder. However, when bit rate reduction is employed, the dynamics of the decoded signal are unchanged. Provided the context is clear, the two meanings can co-exist without a great deal of confusion. There are several reasons why Compression techniques are popular: (a)  Compression extends the playing time of a given storage device. (b)  Compression allows miniaturization. With fewer data to store, the same playing time is obtained with smaller hardware. This is useful in portable and consumer devices. (c)  Tolerances can be relaxed. With fewer data to record, storage density can be reduced, making equipment which is more resistant to adverse environments and which requires less maintenance. (d)  In transmission systems, Compression allows a reduction in bandwidth which will generally result in a reduction in cost. This may make possible some process which would be uneconomic without it. (e)  If a given bandwidth is available to an uncompressed signal, Compression allows faster than real-time transmission within that bandwidth. (f)  If a given bandwidth is available, Compression allows a better-quality signal within that bandwidth. Compression is summarized in Figure 5.1. It will be seen in (a) that the PCM audio data rate is reduced at source by the compressor. The compressed data are then passed through a communication channel and returned to the original audio rate by the expander. The ratio between the source data rate and the channel data rate is called the Compression factor. The term coding gain is also used...

  • The Manual of Photography
    • Elizabeth Allen, Sophie Triantaphillidou(Authors)
    • 2012(Publication Date)
    • Routledge
      (Publisher)

    ...The image histogram will often display one or several peaks, indicating that some pixel values are more probable than others. Measuring Compression rate Lossless Compression algorithms may be evaluated in a number of ways, for example in terms of their complexity; or in the time taken for Compression and deCompression. However, the most common and generally the most useful measures are concerned with the amount of Compression achieved. Compression ratio The Compression ratio is the ratio of the number of bits used to represent the data before Compression, compared to the number of bits used in the compressed file. It may be expressed as a single number (the Compression rate), but more frequently as a simple ratio, for example a Compression ratio of 2:1, which indicates that the compressed file size is half that of the original. Compression percentage Derived from the Compression ratio, the Compression percentage defines the amount of Compression in terms of the reduction in file size in the compressed file as a percentage of the original file size. i.e. if a compressed file is one-fifth the size of the original, then the percentage reduction will be 4/5 × 100 = 80%. Bit rate The bit rate defines the average number of bits required to represent a single sample in the compressed image, i.e. bits per pixel. This is a very commonly used measure, but is only meaningful in comparison with the number of bits per pixel allocated in the uncompressed original. Generally the original image will be 8 or 16 bits per pixel. If an 8-bit image is compressed to a Compression ratio of 2:1, then its compressed bit rate will be 4 bits per pixel. Scene dependency and Compression Although the issue of scene dependency in image quality is covered in detail in Chapter 19, it is mentioned briefly here with respect to image Compression...

  • Digital Image Processing with Application to Digital Cinema
    • KS Thyagarajan(Author)
    • 2005(Publication Date)
    • Routledge
      (Publisher)

    ...That is, there are two broad categories of Compression, namely lossless and lossy. In a lossless Compression the decompressed and original images are identical. Although this may be a boon for the media industries, the amount of achievable Compression ratio is small, typically 2:1. As shown in Table 8-1, this amount of Compression is far below the required value. On the other hand, one can achieve any amount of Compression if a corresponding loss of information is tolerable. Thus, in a lossy Compression scheme, some amount of information is irrecoverably lost at the gain of a large Compression ratio. Thus there is a trade-off between Compression ratio and resulting information loss. This loss of information manifests in the form of visible distortions in the decompressed image. A lot of effort is therefore required in finding ways to hide such distortions so as to minimize the visible artifacts due to the Compression process. The basic idea behind a digital image Compression method is to remove redundant data from the source image. Data redundancy exists either in the spatial domain or, equivalently, in the transform domain. Accordingly, the method of removing data redundancy will differ. Spatial redundancy in an image manifests in the form of closeness in the amplitude of neighboring pixels. Figure 8-1 shows the pixel values along row 128 for the Barbara image. It can be seen from Figure 8-1 that the luminance value of a pixel is very close to its neighbors than to pixels far removed from it. That is, there is predictability in the pixel values—the higher the predictability, the larger the redundancy and vice versa. Another way of quantifying spatial redundancy is pixel correlation. This is shown at the bottom of Figure 8-1 where normalized autocorrelation is plotted against pixel displacement. Again, the correlation stays high over large pixel displacements. This is typical of grayscale images...

  • Understanding Digital Cinema
    eBook - ePub

    Understanding Digital Cinema

    A Professional Handbook

    • Charles S. Swartz, Charles S. Swartz(Authors)
    • 2004(Publication Date)
    • Routledge
      (Publisher)

    ...In one respect this is obviously the ideal form of Compression in that (assuming error-free transmission) there can be no possibility of degradation. This is lossless Compression, and it does have practical applications. Well-known computer programs such as PK-Zip and Stuffit are lossless Compression systems. They can take a computer file, make it more compact for storage or transmission, and then restore a perfect copy of the original. Unfortunately, lossless systems generally do not provide sufficient Compression for large-scale imagery applications such as Digital Cinema distribution. Typically, lossless systems can compress image data by factors in the range of two or three to one; a useful degree of Compression, certainly, but not enough to make Digital Cinema practical. Recently there have been claims that new techniques can provide much higher Compression ratios but—at the time of writing—no independent tests have verified these claims. So the majority of this chapter will be devoted to the characteristics and design of lossy Compression systems; systems that are likely to meet the practical needs of Digital Cinema distribution. However, lossless Compression does still play an important role. These techniques may be used with almost any source of data, including the output data of a lossy Compression system. So practical Compression systems usually consist of a lossy front end followed by a lossless section (known as the entropy coder) to reduce the bit rate even further. Lossy Compression For the foreseeable future, Digital Cinema will require the use of Compression systems that are not lossless: systems that discard or distort some of the information in the original image data, or lossy Compression...

  • The Technology of Video and Audio Streaming
    • David Austerberry(Author)
    • 2013(Publication Date)
    • Routledge
      (Publisher)

    ...These parameters are then coded into data packets for streaming. There are four main redundancies present in the video signal: Spatial Temporal Perceptual Statistical Compression can be lossless or lossy. If all the original information is preserved, the codec is called lossless. A typical example for basic file Compression would be ZIP. To achieve the high levels of Compression demanded by streaming codecs, the luxury of lossless codecs is not possible – the data reduction is insufficient. Spatial redundancy occurs where neighboring pixels in a frame of a video signal are related; it could be an object of a single color. If consecutive pictures also are related there is temporal redundancy. The human visual system has psychovisual redundancy; not all the visual information is treated with the same relevance. An example is lower acuity to color detail than luminance. Finally, not all parameters occur with the same probability in an image. This statistical redundancy can be used in the coding of the image parameters. For example, frequently occurring parameters can be coded with fewer bits (Huffman coding). The goal with Compression is to avoid artifacts that are perceived as unnatural. The fine detail in an image can be degraded gently without losing understanding of the objects in a scene. As an example we can watch a 70-mm print of a movie or a VHS transfer and in both cases still enjoy the experience. If too much Compression is applied, and the artifacts interfere with the image perception, the Compression has become unnaturally lossy. Table 5.1 lists some of the more popular technologies that have been used for encoding streaming files. The techniques may be combined within codecs. For example, MPEG-2 divides the picture into blocks. Each block is encoded using a spatial transform, and the data is then run-length encoded. Blocks that repeat from frame to frame have temporal redundancy...