package simple63

  1. Overview
  2. Docs
Integer compression and decompression module

Install

Dune Dependency

Authors

Maintainers

Sources

simple63-v1.tbz
sha256=7c5393ecea953a18a42fdb5cf16bc082a51a0d99e9c19209f2512526c28b5fe2
sha512=eb2fff2bd7f6433382cb70e46539defb6cdafc66fb8293e799fbbecfa47ccdb3fa740aff787237507282d617386b88374d67836b4c3f72d9e3d0c497d1cf1aef

Description

Simple63 implements a module for compression and decompression of non-negative integer sequences. It is similar to the Simple-8b technique, adapted to work with OCaml's 63-bit integers.

Published: 13 Sep 2020

README

Simple63

Simple63 is an OCaml module for compressing and decompressing sequences of integers along the ideas described in the 2010 paper by Anh and Moffat. Like Simple-8b technique described in that paper, Simple63 is a word-bounded, and (as the name suggests) is the result of adapting Simple-8b to work with OCaml's 63-bit integers. While using int64 integer types would have been possible, the additional boxing required to manipulate int64's make this option unappealing.

Example usage:

let in_lst = [1; 22; 333; 4444] in
let in_seq = List.to_seq in_lst in
let out_seq = encode_to_seq in_seq in

(* confirm that we get out what we've put in: *)
let in_seq' = decode_from_seq out_seq in
let in_lst' = List.of_seq in_seq' in
assert (in_lst = in_lst')

To install:

opam install simple63

Documentation

See https://barko.github.io/simple63

License

BSD

Dependencies (3)

  1. ppx_inline_test
  2. ocaml >= "4.08.0"
  3. dune > "2.6"

Dev Dependencies

None

Used by

None

Conflicts

None

OCaml

Innovation. Community. Security.