[GRASS5] thoughts about runlength encoding
moovida at katamail.com
Wed Aug 11 18:40:16 EDT 2004
just a few thoughts about runlevel encoding.
Perhaps someone can tell me if what I'm saying is right.
When talking about rle in Grass, we are talking about integer (CELL) file
For what I know, Grass's rle is not a standard one.
While standard rle starts compressing equal values after two (or three) of
them have passed, Grass's starts to compress from the first one.
When it compressed, every value gets its counter, so that we can say that a
bunch of coupled is build.
By knowing the compressed size, simply dividing by two we get the number of
couples. Done that it's rather easy to get the uncompressed row.
Is this right? This would mean, that there can't "hybrid" (i.e. couples and
singles) as in the standard rle.
1 1 1 1 1 1 1
1 3 3 3 1 3 1
in Grass gets compressed as:
7 1 =couple
1 3 3 3 1 3 1 =not compressed
as opposed with external rle, where it gets:
1 1 1 5 3 3 3 0 1 3 1
Cheers and thanks for any reply,
"Let it be as much a great honour to take as to give learning,
if you want to be called wise."
Skuggsja' - The King's mirror - 1240 Reykjavik
University of Trento
Department of Civil and Environmental Engineering
Via Mesiano, 77 - Trento (ITALY)
More information about the grass-dev