You are on page 1of 8

SS3A1-A8tyco.

qxp 2/28/06 9:41 AM Page A1

SPECIAL PULLOUT SECTION!


SSIs Master Technician Series

MAKING SENSE
OF
VIDEO
COMPRESSION

Presented by

Brought to You by

MARCH 2006 www.securitysales.com A1


SS3A1-A8tyco.qxp 2/28/06 9:41 AM Page A2

SSIs Master Technician Series

By the Editors of Security


Sales & Integration
secsales@bobit.com

AT A GLANCE
Compression methods reduce
file sizes of images, making stor-
age and transmission more feasi-
Your Video Com p
Now in Session
ble and affordable
Irrelevancy or redundant reduc-
tion is used to eliminate redun-
dant images within video files
JPEG, MPEG, H.26* and wavelet
are best-known compression
standards
From a storage and transmission standpoint, compression is one
Proprietary schemes can be help-
ful in achieving higher compres-
sion and, therefore, lower cost of the key elements that makes digital video recording possible.
American Dynamics Active
Content Compression (ACC) is Knowing the pros and cons of the many different technologies
a proprietary method designed
for security and productivity and techniques will make you more adept at meeting your
management, whereas other
technologies were designed for
other purposes customers surveillance needs.

W
ith so many manufacturers offering DVRs and Compression Reduces File Sizes
NVRs, the many different types of compression The trick to video compression is to remove information
utilized throughout the industry can become no one will notice is missing. If they do, it shouldnt be
very confusing. Which form of compression is best? What something that is too important. There are a lot of tech-
are the different technologies? What is the cost vs. quality niques for removing unneeded video information, which is
between compression methods? What is the difference be- why there are lots of different compression standards. Lets
tween compression standards such as JPEG and MPEG? begin by discussing some of the basic codecs (compres-
What about propriety compression schemes, such as ACC? sor-decompressor or coder-decoder) in use so you can
These are the key questions to ask when dealing with get an idea of some of the tradeoffs involved.
digital video recording whether it is a single DVR or a Consider the requirements needed to store or transmit
large networked system. Brought to you by Tyco Fire & a single minute of composite video to a remote location.
Security, this educational article will provide the answers Without compression, the ability to store this information
that will enable you to offer your customers solutions di- would require a minimum of 1.66GB of storage space. In
rectly from the perspective of a true digital video surveil- the case of video transmitted via a DSL/cable modem throt-
lance expert. tled back to ~600Kbps to 700Kbps to be viewed remotely,

A2 www.securitysales.com MARCH 2006


SS3A1-A8tyco.qxp 2/28/06 9:42 AM Page A3

All photos courtesy Tyco


m pression Lesson Is
it would take about 5.47 hours to transmit from Point A The lossless compression of images is important in fields
to Point B. such as medical imaging and remote sensing, where data
There has always been a tradeoff between the quality of integrity is essential. Typically, compression engines for
video and file size. If you want the best quality in images, lossless codes, including variable-length encoding, are list-
then you have to deal with an enormous file size. For exam- ed as an average of 4:1 compression. In variable-length en-
ple, by decreasing the file size 50 percent, you lose some coding, prior to the writing of the image, the information is
image quality but create a smaller file size that is more con- aligned according to frequency, which plays an important
ducive to recording or transmitting video signals. role in the image compression process.
By no means is the process behind compression easy; For the most part, lower frequencies, which occur more
there is a tremendous amount of mathematical complexity often, are placed to the front while higher frequencies are
required to establish the different compression methods. A placed at the end. In any file, certain characters are used
quick description of the basic parts will help clarify some of more than others. In general, we can attain significant
the theory and explanations discussed later in this article. savings if we use variable-length prefix codes that take
advantage of the relative frequencies of the symbols in
Analyzing the Video Signal the messages to be encoded.
If we analyze the video signal, we see it can be separated Huffman compression is an example of variable-length
into many parts, or subparts, classified by the importance in encoding. Huffmans algorithm compresses files by as-
reference to the images visual quality. A lossy compression signing smaller codes to frequently used characters and
method is one where compressing data and then decom- longer codes to characters that are less frequently used.
pressing it retrieves information that may well be different Using binary code (a sequence of zeros and ones that can
from the original but is close enough to be useful in some uniquely represent a character) representation, the number
way. Thus, the tradeoff is file size vs. image quality vs. cost. of bits required for each character depends on the number
Lossless data compression involves a class of algorithms of characters that have to be represented. One bit can repre-
that allows the exact original data to be reconstructed sent two characters; for example, 0 represents the first char-
from the compressed data. This form of compression is acter and 1 represents the second. Two bits can represent
used when it is important that the original and decom- four characters and so on. Some proprietary compression
pressed data is identical, or when no assumption can be methods refer to this as the delta factor.
made as to whether certain deviation is uncritical. Typical
examples are executable programs and source code. Methods Are Full or Conditional
Some image file formats, notably .png, use only lossless There are several basic avenues of processing a video
compression. Others, like .tiff and .mng, may use either image, all of which fall into the category of either full
lossless or lossy methods. image or conditional compression.

MARCH 2006 www.securitysales.com A3


SS3A1-A8tyco.qxp 2/28/06 9:42 AM Page A4

within a single image or between mul-


tiple images of a video stream.
How JPEG Images Are Processed The first of the three types of redun-
dancy reduction methods is called
N1 - 1 N2 - 1
spatial reduction, which reduces the
[ ] [ ]
k1 k2
B (k1, k2) = 4 A(i, j) cos (2 i + 1) cos (2 j + 1) correlation between neighboring pixel
2 N1 2 N2
i=0 j=0 values. As an example, consider a
white tile floor. Each pixel value will
basically be the same for the entire
Discreet Entropy
cosine Quantizer
encoder
Compressed floor, so why store this same informa-
transform image data
tion over and over when once will do?
The next redundancy reduction
8 X 8 pixel blocks 16 11 10 16 24 40 51 61
method is spectral reduction, which is
12 12 14 19 26 58 60 55
14 13 16 24 40 57 69 56
the correlation between color planes or
14 17 22 29 51 87 89 62 bands within an image. As an example,
18 22 37 56 68 109 103 77
24 35 55 64 81 104 113 92 consider a blue sky. Many areas of that
49 64 78 87 103 121 120 101
72 92 95 98 112 100 103 99 sky have the same numeric value.
Quantization table Therefore, the amount of stored infor-
mation to reproduce that same image
The discrete cosine transform (DCT) helps separate the image into parts (or spectral
can be reduced.
subbands) of differing importance with respect to the images visual quality.
The last area is known as temporal
reduction, which is the correlation be-
The full image approach usually relates to Joint Photo- tween adjacent frames in a sequence. This information is
graphic Experts Group (JPEG) and wavelet compression, the basis for MPEG as well as the H.26* series of compres-
in which the entire image is analyzed, compressed and sion methods.
stored. In most cases, this form of analyzing an image can Temporal reduction looks at two types of image
only provide a limited amount of compression, meaning arrangements. The first one is a full representation of the
larger file sizes and increased storage space requirements. viewed image. This is known as the I-frame and is en-
With conditional compression, only changes from coded as a single image, with no reference to any past or
image to image, or to adjacent image, are analyzed and future images. In some circles, it is also referred as the
compressed. This method is usually associated with Mov- Key-frame. The concept behind the temporal method is if
ing Picture Experts Group (MPEG), modified MPEG com- there are no movements then why bother saving the in-
pression methods and the H.26* series of compression. formation? Conversely, any movement will be detected
and the compression process will begin.
2 Types of Reduction Explained
Most types of image files are fairly redundant they have How Video Frames Are Handled
the same information listed over and over again. File com- The compression forms detailed in the preceding sec-
pression programs simply get rid of the redundancy. Instead tion are the foundation for todays compression standards.
of repeatedly listing a piece of information, a file compres- There are some additional terms, however, that will help in
sion program defines that data once and then refers back to understanding the differences among those methods
it whenever it appears in the original program. The major Intraframe is compression applied to still images, such
image reduction schemes are irrelevancy reduction and as photographs and diagrams, and exploits the redun-
redundant reduction. dancy within the image, known as spatial redundancy. In-
Irrelevancy reduction omits the parts of the video sig- traframe compression techniques can be applied to indi-
nal that are not noticed or perceived by the signal receiv- vidual frames of a video sequence.
er, which in this case is the human eye. Through the re- Subsampling is the most basic of all image compression
search of Human Visual Systems (HVS), it has been proven techniques and reduces the amount of data by throwing
that small color changes are perceived less accurately some of it away. Subsampling reduces the number of bits
than small changes in brightness, so why brother saving required to describe an image, but the quality of the sub-
this information? sampled image is lower than that of the original.
It is also known that low-frequency changes are more Subsampling usually takes place in one of two ways. In
noticeable to the human eye than high-frequency the first, the original image is copied but only a fraction of
changes. Low frequencies control the coarser or more the pixels from it are used. Alternatively, subsampling can
noticeable conditions of a video image, whereas higher be implemented by calculating the average pixel value for
frequencies are usually related to the finer details of a each group of several pixels and then substituting this av-
video image. erage in the appropriate place in the approximated image.
Redundancy reduction is accomplished by removing The latter technique is more complex but generally pro-
duplication from the signal source, which is found either duces better quality images.

A4 www.securitysales.com MARCH 2006


SS3A1-A8tyco.qxp 2/28/06 9:42 AM Page A5

Interframe is compression applied to a sequence of tions of an image. This compression then uses fractal algo-
video frames rather than a single image. In general, rela- rithms. Fractal is a generalization of an information-free,
tively little changes from one video frame to the next. In- object-based compression scheme rather than a quantiza-
terframe compression exploits the similarities between tion matrix. It uses a set repetitive in shape but not size.
successive frames, known as temporal redundancy, to re- DWT compresses an image by frequency ranges. It filters
duce the volume of data required to describe the sequence. the entire image, both high and low frequencies, and repeats
There are several interframe compression techniques of this procedure several times. Wavelet compression utilizes
varying degrees of complexity. Most of them attempt to more the entire image, which differs from many DCT methods.
efficiently describe the sequence by reusing parts of frames
the receiver already has in order to construct new frames. Standards Include JPEG, MPEG
Subsampling can also be applied to video as an inter- What are the different compression systems available
frame compression technique by transmitting only some in the security marketplace? The first group can be listed
of the frames. Subsampled digital video might, for exam- as compression standards. These are standards that have
ple, contain only every second frame. Either the viewers been approved by various agencies and have been guided
brain or the decoder would be required to interpolate the by groups of individuals and committees. They include
missing frames at the receiving end. Joint Photographic Exports Group (JPEG), Moving Pictures
Difference coding or conditional replenishment is a very Expert Group (MPEG), International Telecommunication
simple interframe compression process during which each Union (ITU) and International Standards Organization
frame of a sequence is compared with its predecessor, and (ISO) just to name a few.
only pixels that have changed are updated. In this way, only Now that we are familiar with the different compres-
a fraction of the number of pixel values is transmitted. sion theories and the ways video information is reduced,
we can apply this knowledge to the industrys various
Next Step in Process: Quantization compression standards.
Following the signal analysis, the next part is the quantizer. JPEG This is a lossy compression method, meaning the
Quantization is simply the process of decreasing the num- decompressed image isnt quite the same as the one in
ber of bits needed to store a set of values
or transformed coefficients as they are
called in data compression language. How H.264 Images Are Processed
Since quantization is a many-to-one Rate control
mapping and reduces the precision of Video in
Quantizer Buffer Coded
those values, it is known as a lossy Transform Coder image
process (as opposed to lossless) and is
the main source of compression in most Inverse
image coding schemes. quantizer
There is a tradeoff between image
quality and degree of quantization. A
Inverse
large quantization step size can pro- transform
duce unacceptably large image distor-
tion. Compression methods use four
types of quantization: discrete cosine Motion
compensated
transform (DCT), vector quantization predictor
(VQ), fractal compression and discrete
wavelet transform (DWT).
Motion Motion vectors
DCT is a lossy compression algo- estimator
rithm that samples the image at regu-
lar intervals. It analyzes the compo-
In theory, H.264 is based on block transforms and motion-compensated predictive cod-
nents and discards those that do not
ing. Motion estimation is used to identify and eliminate the temporal redundancies that
affect the image as perceived by the exist between individual pictures.
human eye. JPEG, MPEG, H.261, H.263
and H.264 are a few compression standards that incorpo- which you started. JPEG is designed to exploit known lim-
rate DCT. itations of the human eye, notably the fact that small
VQ is also a lossy compression that looks at an array of color changes are perceived less accurately than small
important, instead of individual, values. Vector quantiza- changes in brightness. Thus, it is intended for compress-
tion generalizes what it sees, compresses redundant in- ing images that will be viewed by humans.
formation and tries to retain the desired information as Data compression is achieved by concentrating on the
close to the original as possible. lower spatial frequencies. According to the standard,
Fractal compression is a form of VQ; however, this type modest compression of 20:1 can be achieved with only a
of compression locates and compresses self-similar sec- small amount of image degrading. However, if you plan to

MARCH 2006 www.securitysales.com A5


SS3A1-A8tyco.qxp 2/28/06 9:42 AM Page A6

machine-analyze your information, the small errors gen- The MPEG-2 standard has a resolution of 720 X 480 pix-
erated by JPEG may cause problems. els (4 CIF) and incorporates both progressive and inter-
The Joint Photographic Experts Group has approved laced scanning. Interlaced scanning is the method used
the next standard for image compression, known as in the CCTV industry to produce images on monitors.
JPEG2000, which is based on wavelet compression algo- MPEG-2s most significant improvement over MPEG-1 is
rithms. By setting the mother wave for image compres- its ability to efficiently compress interlaced video. It is also
sion and decompression ahead of time as a part of the capable of coding standard-definition television at bit rates
standard, JPEG2000 will be able to provide quality resolu- from about 3Mbps to 15Mbps and high-definition televi-
tion at a compression of 200:1. sion. Compression ratios for MPEG-2 vary, depending on
MPEG There are many different areas to this compres- the type of signal and number of B-, P- and I-frames. On av-
sion standard. Each has its very own special features, and erage, the ratio goes from 50:1 to 100:1.
improvements are consistently being incorporated that The MPEG-4 standard is used for multimedia and Web
add to the existing standard. However, the basics are sim- compression because it is designed for low bit-rate transmis-
ilar for all versions. MPEG incorporates the same com- sion. MPEG-4 utilizes object-based compression in which in-
pression methods as JPEG (DCT ). However, MPEG is dividual objects within a scene are tracked separately and
based on the group of images concept. The group of im- compressed together. This method offers a very efficient
ages is defined as the I-frame, P-Frame and B-Frame. compression ratio that is scalable from 20:1 up to 300:1.
The I-frame (intra) provides the starting or access point
and offers only a small amount of compression. P-frames H.26* series This group of compression standards is the
(predicted) are coded with reference to a previous picture, result of the telecommunications industry and has also been
which can be either an I-frame or another P-frame. B- adopted by the security industry for remote video viewing.
frames (bi-directional) are intended to be compressed The H.263 video compression algorithm is designed for low
with a low bit rate, using both the previous and future ref- bit-rate communications. The video source-coding algo-
erences. B-frames are never used as references. rithm of H.263 is a hybrid of inter-picture prediction that
uses temporal redundancy and trans-
forms the coding of the remaining signal
How ACC Images Are Processed to reduce spatial redundancy.
H.263 can achieve picture quality as
Video input Noise Interframe Run length high as H.261 with 30 percent to 50 per-
immunity delta analyzer encoder cent of the bit usage. Because of its low
resolutions and low bit rates for trans-
mitting video images, H.263 is also better
than MPEG-1/MPEG-2. The compres-
DC transform sion ratio of H.263 can reach up to 200:1.
Manufacturers have made many ad-
vances during the past year in the com-
pression standards they are offering.
Quantizer H.264 is one of those advancements. In
theory, H.264 is based on block trans-
forms and motion-compensated pre-
dictive coding. Motion estimation is
Huffman used to identify and eliminate the tem-
Coded image
coder poral redundancies that exist between
individual pictures.
ACC uses the intraframe technique to compress the first image, or what is referred to as H.264 leverages todays processing
the reference frame or I frame, which represents the complete image. It also incorpo- power to provide improved coding
rates interframe and noise immunity to compress the subsequent 31 images to create techniques, including multiple refer-
what is known as a prediction or updated frame. ence frames and variable block sizes
for motion compensation, intraframe
The relationship between the three frame types is de- prediction, an integer transform, an in-the-loop deblock-
scribed in the MPEG standard; however, it does not re- ing filter and improved entropy coding.
strict the limit of B-frames between the two references or Wavelet This compression standard does not use DCT;
the number of images between two I-frames. instead it incorporates the use of frequency filtration. The
The MPEG-1 standard has a resolution of 352 X 240 pix- advantage of wavelet compression is that, in contrast to
els common interchangeable (or intermediate) format JPEG and MPEG, its algorithm does not divide the image
(CIF) at 30 images a second and incorporates progressive into 8 X 8 blocks as found with DCT. This characteristic
scanning. It is designed for up to 1.5Mbps with compres- allows wavelet to obtain good compression ratios while
sion ratios listed as 27:1. maintaining optimal image quality.

A6 www.securitysales.com MARCH 2006


SS3A1-A8tyco.qxp 2/28/06 9:42 AM Page A7

The filtering schemes rely on the image parts that are lent of a series of images recorded at the rate of 30 fps and
not noticed by the human eye. The more the filtering oc- you have the following:
curs, the smaller the overall file size of the images and the
lower the image quality will be when decompressed. 640(h) pixels X 480(w) pixels X 3 bytes/pixel =
With the addition of the previously mentioned JPEG2000, 0.88MB/image
the approach taken by the Joint Photographic Experts Group 0.88 MB/image X 30 images/second = 26.37MB/second
is changing from DCT to wavelet compression. 26.37MB/seconds X 3,600 seconds/ hour =
94,921.88MB/hour
Not All Methods Are Standards 94,921.88MB/hour X 24 hours/day = 2,278,125MB/day
There are several compression methods that have been
incorporated in the security industry that have not offi- To store this much video data without any compression,
you would need more than eight 300GB
hard drives. Downloading it would take
Cost-Effectiveness Comparison of ACC vs. MPEG-4 several days using a T-3 line (45Mbps).
Storage in Terabytes ACC uses three forms of compres-
(100 cameras @ 2CIF, 15 ips for 30 days) sion: intraframe, interframe and noise
MPEG-4 ACC saves immunity.
$69,032
ACC Before continuing, lets talk a bit
32.98TB
about the critical role of noise in video
ACC saves ACC saves
$62,493 $59,451 compression. Noise is present in all
20.32TB ACC saves 21.71TB systems and is usually related to the
$44,978 quality of the video input signal. All
14.33TB
compression systems compress any
changes to a video signal, including
2.47TB 1.48TB 4.73TB 13.26TB noise. The result is increased file sizes,
Indoor Indoor Outdoor Outdoor night which in turn cause increases in stor-
low light
age space and bandwidth require-
Proprietary compression schemes in the marketplace today include American Dynamics ments, especially when networking is
active content compression (ACC). This technique focuses on the importance of delivering
involved.
quality digital video that is both economically and technologically feasible. These costs
are based on the industry average of $3,500/TB. Since noise is a major player when it
comes to compression and file sizes, it
cially been adopted as standards. These typically are is only natural that it should be a consideration in com-
modified versions of those that have been established as pression methods.
standard but with added tweaks and capabilities. ACC uses the intraframe technique to compress the
Motion-JPEG (M-JPEG) is a video codec that compress- first image, or what is referred to as the reference frame or
es each video field separately into a JPEG image. The re- I frame, which represents the complete image. It also in-
sulting quality of intraframe video compression is inde- corporates interframe and noise immunity to compress
pendent from the motion in the image. This differs from the subsequent 31 images to create what is known as a
MPEG video where quality often decreases when the prediction or updated frame. This includes only active
video image contains lots of movement. M-JPEG is often content or changers within the image.
used as a storage format for large video files that need to This proprietary encoding technology, which is used in
be archived with good quality. It is a lossy compression, ADs Intellex digital recording systems, makes manipula-
but at high quality, the image degradation is minimal. tion and/or alteration of the original recorded video data
stream virtually impossible and ensures the authenticity
How Proprietary Schemes Fit In of the recorded video. Since ACC does not provide any
There are also many proprietary compression schemes method to edit the original recorded video stream, it pro-
available, such as Active Content Compression (ACC) from tects the court admissibility of your video evidence.
American Dynamics, a division of Tyco Fire & Security.
While other video compression technologies originated Base Compression on Application
to serve other purposes, ACC was developed specifically With all of the different types of reduction methods
for security and productivity management. available for video images and the many different com-
This compression technique focuses on the impor- pressions, it is no wonder many people get confused with
tance of delivering quality digital video that is both eco- digital video storage and transmitting equipment.
nomically and technologically feasible. This is critical With each form of information reduction method or
when you consider the staggering amount of data gener- compression standard, there is one single item to keep in
ated by one camera alone during a 24-hour period. mind: The quality of the reproduced image whether
A single video image comprising 640 X 480 pixels (4 from a storage device such as a DVR or a remote location
CIF) represents 0.88MB. Now add motion in the equiva- will depend on the application of that system.

MARCH 2006 www.securitysales.com A7


SS3A1-A8tyco.qxp 2/28/06 9:42 AM Page A8

Introducing the powerful,


compact Intellex Ultra.

You would need


twice as many
competitive DVRs
40U to match the
capabilities of the
32U new Intellex Ultra.

12U

5U 4U
3U

Competitor A Competitor B Intellex Ultra

For performance, reliability, integration and more,


its the greatest value for your money.
TWICE THE PERFORMANCE. USES LESS STORAGE AND BANDWIDTH.
Supports 640 x 480 (4 CIF) at 240 ips and 640 x 240 Active Content Compression (ACC) technology
(2 CIF) at 480 ips double the resolution and frame results in high quality video files up to 9 times
rate of any DVR in its class. smaller than MPEG-4 or MJPEG.

LOWEST PRICE PER CHANNEL IN ITS CLASS. MORE RELIABLE.


Costs up to 50% less than comparable DVRs based A separate solid state system drive maintains viability
on assumed best dealer pricing. even in the unlikely event of hard drive failure.

TAKES UP LESS RACK SPACE. SEAMLESS INTEGRATION.


25-40% smaller than the competition, and you need The most comprehensive and easy-to-use API in the
fewer Intellex Ultra units for the same performance. industry seamlessly integrates with numerous
third-party applications including Software House
and Kantech access control systems.
Get more details about Intellex Ultra and the full Intellex product line at
www.americandynamics.net/intellex.

You might also like