Questions tagged [text-compression]
29 questions
35
votes
3 answers
What is the current state of text-only compression algorithms?
In honor of the Hutter Prize,
what are the top algorithms (and a quick description of each) for text compression?
Note: The intent of this question is to get a description of compression algorithms, not of compression programs.

Brian R. Bondy
- 339,232
- 124
- 596
- 636
6
votes
1 answer
Haskell Linear-Time Online Algorithm
Please forgive me if I misused the big words in the title; I'm not too knowledgeable about them but hope they describe my problem. I wrote an elaborate scheme to try and encode strings according to these requirements. For strings of length 10^4 and…

גלעד ברקן
- 23,602
- 3
- 25
- 61
5
votes
4 answers
What's the best practice for storing huge amounts of text (into a DB or as a file?), and what about compressing it?
I'm building a web-app that handles internal emails and other frequent small-to-medium sized chunks of text between users and clients. What's the best method for storing this data? In a database (MySQL) or as thousands of individual files? What…

Seth
- 1,550
- 3
- 16
- 20
5
votes
1 answer
What is the name of this text compression scheme?
A couple years ago I read about a very lightweight text compression algorithm, and now I can't find a reference or remember its name.
It used the difference between each successive pair of characters. Since, for example, a lowercase letter predicts…

Potatoswatter
- 134,909
- 25
- 265
- 421
3
votes
3 answers
2
votes
1 answer
Best compression and decompression algorithm for qrcode
Scenario: Have to generate qr code which contains some customer information. It will be scanned in android phone.
The information have to transfer in following process.
----------------------Server side---------|| Image…

Amir
- 1,066
- 1
- 13
- 26
2
votes
3 answers
Text Compression Algorithm
I am just wondering if someone could introduce me any algorithm that compresses Unicode text to 10-20 percent of its original size ?
actually I've read Lempel-Ziv compression algorithm which reduces size of text to 60% of original size, but I've…

Bahram
- 1,464
- 2
- 22
- 38
2
votes
3 answers
Compressing a string, end result without line breaks?
I'm trying to compress any given string to a shorter version, copy paste-able compressed string that doesn't contain any line breaks.
I tried gzcompress, but then copy/pasting the result into a different php script and trying to gzuncompress throws…

Andrei Serdeliuc ॐ
- 5,828
- 5
- 39
- 66
2
votes
2 answers
Compressing small piece of data
I have a buffer of let's say 4KB, containing data in JSON-like format. I need to add significantly more information (up to let's say 3x more) to it, but I have to fit in this small chunk of memory. I was thinking about using libZ to compress text,…

k_wisniewski
- 2,439
- 3
- 24
- 31
1
vote
3 answers
Blazor / ASP.NET Text Compression - Google speed test do not agree, why?
I have a blazor application where I added text compression, that way:
context.Services.AddResponseCompression(o =>
{
o.EnableForHttps = true;
});
// We use Brotli by default :…

ClubberLang
- 1,624
- 3
- 21
- 45
1
vote
0 answers
How to get the same byte Array after stored it as String?
I have used Java code to compress a string to a byte array and then I store this byte array as a string in Cloud database. The decrypted message needs the same byte array which was returned by the compress method. So how to get the same byte array…

Shuvendu Dhal
- 75
- 2
- 6
1
vote
5 answers
How come, different text files become different sizes after compression?
I have file of some random text size = 27 gb and after compression it becomes 40 mb or so.
And a 3.5 GB sql file become 45 Mb after compression.
But a 109 mb text file become 72 mb after compression so what can be wrong with it.
Why so less…

Arshdeep
- 4,281
- 7
- 31
- 46
1
vote
2 answers
LZW compression on text
How can the LZW output sequence be improved to achieve higher compression? Are there any specific methods? (I am applying LZW compression on a text file)

user4345738
- 191
- 9
0
votes
0 answers
How can I enable text compression in Gen4 VPS Linux 4 CPU
I have a server Gen4 VPS Linux 4 CPU where I have website called https://www.academiaerp.com/ and https://www.academiaerp.com/staging/. I was checking website speed using page speed insights and GTmetrix both of them mentioned I need to enabled text…

Sai Praveen
- 1
- 1
0
votes
0 answers
Text compression in tomcat is not working for some requests with same content type
I am using Spring Boot version 2.7.9. Currently I am trying to enable text compression in my application, where the property file looks like…

Heyyou
- 151
- 1
- 13