Unit 1.3 - Data storage and compression Flashcards

1
Q

List the different units of size

A

1 Bit
2. Nibble - 4 bits
3. Byte - 8 bits
4. KiB, kibibyte - 1024 bytes
5. MiB, mebibyte - 1024 KiB
6. GiB, gibibytes - 1024 mebibytes
7. TiB, tebibyte - 1024 GiB
8. PiB, pebibyte - 1024 TiB
9. EiB, exbibyte - 1024 PiB

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

What is compression?

A

The act of reducing the size of a file to save storage space by applying an algorithm to it.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

What are some benefits of compression?

A

Compressed files take up less space on the storage device, requires less bandwidth and transmission takes less time

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

What is bandwidth?

A

The maximum data transfer rate of a network

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

What are files types that apply no compression called?

A

RAW files

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

What is lossy compression and how does it work?

A

Lossy compression permanently removes some data from the original file. For example, in image files some pixels may be removed, and in sound files frequencies outside the human hearing range may be removed too.
This is suitable for files that have a lot of unique information like bitmap graphics, audio or video files. File types that go through lossy compression include : .mp3, .jpg, .gif, .mp4.
Not suitable for anything that needs to be reproduced exactly such as software, texts, etc. as they will become corrupted if data is removed
Reduces file size by a lot more than lossless compression but can result in decreased quality, though usually not noticeable.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

What is lossless compression and how does it work?

A

Lossless compression reduces the file size without losing any of the original data. It does so by searching for patterns and repeated information in the file (repeated words, sequences of pixels, etc) and instead of giving each data a unique code, it stores the data, indexes it and assigns repeated blocks of data the same values/code.
Examples of file types that have lossless compression are .zip, .png, .tif and .svg.
Not suitable for files that do not have many patterns/repeating information.
Files don’t lose any quality with the cost of a larger file size than during lossy compression.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

Name and explain the 2 types of lossless compression

A
  1. Run length encoding / RLE - compresses and stores duplicate data in an efficient way. Often used of image files, where it stores runs of data (consecutive pixels) with the same color by recording the entire string, and not giving each pixel a unique code. For example, if the first 16 pixels are the same colour, instead of storing them with 16 bits, we could only use 6, by using the first 5 to say how many pixels there and the last bit to say which colour they are.
  2. Dictionary encoding - mainly used for text messages, this algorithm generates an index of repeated words and gives them the same code which requires less space to store.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly