Tutorial

Installing and using Integer Encoding Library

To begin benchmarking, run the following command in the top directory:
[prettify]make bench[/prettify]
The command above generates two executable files: encoders and decoders. Currently, encoders supports 13 different encoding algorithms, and decoders supports 18 different decoding ones. Please, refer to README.md for more details regarding the IDs of this algorithm.
For example, the following command
[prettify]./encoders 8 gov2.sort[/prettify]
encodes the dataset gov2.sort in Download by using  VSEncodingBlocks (Encoder ID: 8, Decoder ID:13).

You can run the command with the option -i to see the progress ratio and the expected time of completion. Instead, the option -r can be used to resume a disrupted encoding process.

As a result of the encoding we obtain two files,  gov2.sort.VSE.DEC and gov2.sort.VSE.TOC. The first one is the compress while the second one contains few information regarding the inverted lists that are needed during the decompression.

We can decode the above files by running the following command:
[prettify]./decoders 13 gov2.sort[/prettify]
Notice that we need to set the correct decoder ID. In this example we use 13 which is the decode ID for VSEncodingBlocks.
Obviously, you can use the library by calling its functions directly from your code. For this aim, it is possible to build it as a shared library simply by running:
[prettify]make[/prettify]
The use of Decode and Encode functions is pretty simple. Please, check src/encodes.cpp and src/decoders.cpp in our git repository to understand their simple use.