Тест современных компрессоров для HTTP

Сжатие текста уже давно стало стандартом в мире веб‑приложений. Сокращение объёма данных даёт сокращение времени передачи и снижение нагрузки на сетевой канал. Однако, часто настройка компрессии сводится к динамическому сжатию gzip и настройкам по умолчанию. В этой статье разберём вопрос сжатия более глубоко. Для начала вспомним основные технологии сжатия, доступные в вебе.

https://habr.com/ru/articles/1040692/

#angie #gzip #brotli #zstd #zstandard

Тест современных компрессоров для HTTP

Сжатие текста уже давно стало стандартом в мире веб‑приложений. Сокращение объёма данных даёт сокращение времени передачи и снижение нагрузки на сетевой канал. Однако, часто настройка...

Хабр

Let's say you want to compress a file with gzip. That's easy:

gzip foo.txt

Now foo.txt is gone and you have a (presumably smaller) foo.txt.gz instead.

You've heard that 7-zip can produce files in gzip format, but with better compression. What would an equivalent command look like if you were to use 7z?

7z is an archiver, not a compressor. As far as it is concerned, gzip is an archive format that can only store a single file. To create a .gz file, we need to add a file to it:

7z a -tgzip foo.txt.gz foo.txt

The -tgzip flag tells 7z to create an "archive" in gzip format. (It is technically redundant here because 7z can derive the type of the archive from its filename, but I like to be explicit.)

However, this leaves foo.txt untouched. To delete the input file after the .gz file has been written successfully, pass -sdel:

7z a -tgzip -sdel foo.txt.gz foo.txt

This works! But unlike gzip, 7z is very chatty by default and outputs all kinds of nonsense like "Copyright (c) 1999-2023 Igor Pavlov" or "Scanning the drive" or "Everything is Ok". To shut it up, you add a few more flags:

7z a -tgzip -sdel -bso0 -bsp0 foo.txt.gz foo.txt

This tells 7z to redirect regular output ("o") and progress ("p") messages to stream "0", which is not a real stream, but suppresses all output. Error messages are left at their default setting, -bse2, which means they are written to stream "2" (standard error).

Finally, you realize that maybe you didn't have to switch to a completely different program. You could have told gzip to expend more effort to compress better:

gzip -9 foo.txt

But 7z also has tunable compression parameters. Cranking everything to the max for gzip gives:

7z a -tgzip -sdel -bso0 -bsp0 -mx=9 -mfb=258 -mpass=15 foo.txt.gz foo.txt

#gzip #7zip

[Перевод] Как уместить DOOM в QR-код

DOOM известен тем, что запускается где угодно – благодаря портам, которые появляются с 1993 года. Мем «It Runs Doom» («Он запускает DOOM») живёт в интернете уже больше десяти лет. Люди запускали DOOM на тостерах, на тачбарах макбуков, на умных холодильниках. И, кажется, я – первый человек, который уместил DOOM в QR-код.

https://habr.com/ru/companies/cloud4y/articles/1038838/

#DOOM #QRкод #JavaScript #HTML #минификация #сжатие_данных #gzip #DecompressionStream #Web_API #raycasting

Как уместить DOOM в QR-код

DOOM известен тем, что запускается где угодно – различные порты игры появляются с 1993 года. Мем «It Runs Doom» живёт в интернете уже больше десяти лет. Люди запускали DOOM на тостерах, на тачбарах...

Хабр
WinRAR archiver, a powerful tool to process RAR and ZIP files

WinRAR provides the full RAR and ZIP file support, can decompress CAB, GZIP and other archive formats

Tar fediverse

tar -cvfz fediverse.raw fediverse.tgz`

ls -lh

fediverse.raw 2.048 PiB

fediverse.tgz 1.36 TiB

According to my version of tar(1) it's entirely doable

/me grins 😁

sources
man tar(1)
man gnu

@stefano @justine

corrected for syntax

#tar #GNU #gnutar #cvfz #gzip #compression #fediverse #mathematics #technology #OpenSource #Linux #BSD

Zip / gzip Multiplatform Native Plugin. | Input Management | Unity Asset Store

Get the Zip / gzip Multiplatform Native Plugin. package from A dog's life software and speed up your game development process. Find this & other Input Management options on the Unity Asset Store.

[Перевод] Почему GZIP сыпал исключениями только в жару и в дождь

В квартире стояла летняя жара. Впрочем, ненадолго: хозяин квартиры как раз привез мне кондиционер, и его пора было запускать. Через несколько недель Я писал на C# программу для распаковки gzip-файлов и неожиданно поймал странное исключение, из которого следовало, что архив поврежден. Ситуация выглядела дико: ошибка намекала на поврежденный архив, хотя сам файл не выглядел реально битым. Сказать, что это напрягало значит ничего не сказать...

https://habr.com/ru/articles/1016532/

#bash #gzip #c# #exception

Почему GZIP сыпал исключениями только в жару и в дождь

В квартире стояла летняя жара. Впрочем, ненадолго: хозяин квартиры как раз привез мне кондиционер, и его пора было запускать. Через несколько недель Я писал на C# программу для распаковки gzip-файлов...

Хабр
gzip decompression in 250 lines of rust | ian erik varatalu

ian erik varatalu
An ode to bzip

The story goes like this. ComputerCraft is a mod that adds programming to Minecraft. You write Lua code that gets executed by a bespoke interpreter with access to world APIs, and now you’re writing code instead of having fun. Computers have limited disk space, and my /nix folder is growing out of control, so I need to compress code. The laziest option would be to use LibDeflate, but its decoder is larger than both the gains from compression and my personal boundary for copying code. So the question becomes: what’s the shortest, simplest, most ratio-efficient compression algorithm? I initially thought this was a complex question full of tradeoffs, but it turns out it’s very clear-cut. My answer is bzip, even though this algorithm has been critiqued multiple times and has fallen into obscurity since xz and zstd became popular.

purplesyringa's blog

Sembra incredibile ma sono ancora qui a pubblicare dei videi nonostante gli impegni sempre più impegnativi. Merito almeno un singolo applauso.

Speciale 5000 iscritti: come funziona la compressione dei dati che viaggiano su internet. Da Shannon (l'unico Claude di cui potete fidarvi al 100%) agli algoritmi classici, fino ai tre protagonisti della compressione moderna: gzip, Brotli, Zstandard.

E "one more thing": il nuovo OpenZL di Meta.

https://youtu.be/ohgfRVRncbQ

#compressione #gzip #brotli #zstandard #openzl

Compressione: perché ogni bit conta (speciale 5000 iscritti) - Buongiorno 318

YouTube