1.3 - data storage and compression ๐ Flashcards
what systems exist for measuring memory size?
SI denary (kilobytes, megabytes, gigabytes, etc.) + IEC binary (kibibytes, mebibytes, gibibytes, etc.)
whatโs the equation for image file size?
file size = resolution * color depth
whatโs the equation for audio file size?
file size = sample rate * resolution * sample length
how does lossy compression work?
it permanently erases all metadata deemed unnecessary from a file reducing in a smaller file that canโt be used to reconstruct the original file
what are some examples of lossy file formats?
MP3 (only includes sounds within the human hearing range), JPEG (separates pixel colors and brightness levels in the original bitmap from each other)
how does lossless compression work?
it effectively ensures no dataโs permanently lost via RLE when there are long runs of repeated bits in the original file while still creating a smaller file
what are some examples of lossless file formats?
WAV (can include sounds outside the human hearing range while also not perceptually shaping the audio), PNG (keeps the same pixel colors and brightness that were in the original bitmap)
when should lossy compression NEVER be used?
if the file to be compressed could become permanently corrupted with this kinda compression (eg. complex XLSX spreadsheets/large APKs and MSIs/ISO and DMG files for installing new OSes)