Download Chapter 2 - Philadelphia University Jordan

Survey
yes no Was this document useful for you?
   Thank you for your participation!

* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project

Document related concepts
no text concepts found
Transcript
Chapter 2
Digital data
Ola A. Younis
Elements of digital media
• Symbols: representation for something else. Example: a
group of letters often serve as symbols of words.
• Data: the givens of experience-mesurments, facts,
observations and beliefs. Example: a list of numbers ( 12, 9, 20….)
• Data is either digital or analog.
• Information: data made useful, data interpreted and
applied to produce understanding. Example: the previous list of
numbers are hours!
Digital codes
Digital information starts with digital data, and digital
data starts with digits (0-9).
• Bits : binary digit…. 0 or 1.
• Bytes: 8-bit code=256 distinct item.
• Effective code: is one that can represent each
desired data item with unique combination of
symbols.
• Efficient code: is one that does not waste
processing, storage or transmission storage.
Files
A computer file is a container for binary code, which
is the universal language of a computer.
• Size: measured in number of bytes, Kilobyte=2
Gigabyte=230 or Terabyte=2
, Megabyte=2
, 20
10
40
• Format: a convention that specifies how instructions and data are
encoded in computer file.
• File extension..
• File Compatibility: assuring that a computer can process the
instructions or data that are encoded in a particular data format.
• Maintenance: Identification, categorization and
preservation.
GIF
5
Li & Drew
6
GIF87
Li & Drew
• For the standard specification, the general file format of a GIF87
file is as in Fig. 2.2.
Fig. 2.2: GIF file
format.
7
Li & Drew
• Screen Descriptor comprises a set of attributes that belong to every image in
the file. According to the GIF87 standard, it is defined as in Fig. 2.3
Fig. 2.3: GIF screen descriptor.
8
Li & Drew
• Color Map is set up in a very simple fashion as in Fig. 2.4 However, the
actual length of the table equals 2(pixel+1) as given in the Screen Descriptor.
Fig. 2.4: GIF color map.
9
Li & Drew
• Each image in the file has its own Image Descriptor, defined
as in Fig. 3.15.
Fig. 2.5: GIF image descriptor.
Digitization
The process of converting analog data to digital format is called
digitization and it starts with sampling.
• Sampling: the process of analyzing small element of an image or
sound and representing that element in a digital code.
• Quantization: the process of rounding off the value of sample to the
closest available value in the digital code being used.
• Sample resolution: number of bits used to represent a digital
sample.
• Sample rate: the number of samples taken in a given unit of time.
11
Li & Drew
• Fig. 2.6: An analog signal: continuous measurement
of pressure wave.
12
Li & Drew
• • The graph in Fig. 2.7 has to be made digital in both time and
amplitude. To digitize, the signal must be sampled in each
dimension: in time, and in amplitude.
▫
(a) Sampling means measuring the quantity we are interested
in, usually at evenly-spaced intervals.
▫ (b) The first kind of sampling, using measurements only at evenly
spaced time intervals, is simply called, sampling. The rate at
which it is performed is called the sampling frequency (see Fig.
2.7(a)).
▫ (c) For audio, typical sampling rates are from 8 kHz (8,000
samples per second) to 48 kHz. This range is determined by the
Nyquist theorem, discussed later.
▫ (d) Sampling in the amplitude or voltage dimension is called
quantization. Fig. 2.7(b) shows this kind of sampling.
13
Li & Drew
(a)
(b)
•Fig. 2.7: Sampling and Quantization. (a): Sampling the
analog signal in the time dimension. (b): Quantization is
sampling the analog signal in the amplitude dimension.