/bsc

Python binding for libbsc, a fast yet capable compressor

Primary LanguageCMIT LicenseMIT

BSC: Python bingding for libbsc

Install

pip install bsc

Usage

API mimics zlib's

import bsc
assert b'1234' == bsc.decompress(bsc.compress(b'1234'))

# Incremental compressing
# Note that default block size is 25M, you'd better use it on
# very large streams
c = bsc.compressobj()
r = c.compress(b'1234')
r += c.compress(b'2345')
r += c.flush()

Performance

See Squash Benchmark

Link

libbsc