Python bindings for the Zstandard compression library, providing high compression ratios and fast decompression speeds. Current version: 0.25.0. Released on a regular basis with active maintenance.
pip install zstandardVerified import paths — ran on the pinned version, not inferred.
Basic usage example demonstrating compression and decompression with zstandard.
Upgrade to Python 3.9 or later.
Update wheel distribution to 'manylinux2014' or 'manylinux2010'.
pip install zstandard
Install the appropriate build tools for your operating system (e.g., `build-essential` on Debian/Ubuntu, Xcode command line tools on macOS, or Visual C++ build tools on Windows) before running `pip install zstandard`.
Verify the integrity and completeness of the compressed input data. Ensure that the data was indeed compressed using Zstandard and that any required dictionaries are correctly applied during decompression.
Create an instance of the `ZstdCompressor` or `ZstdDecompressor` class to perform compression/decompression, e.g., `cctx = zstandard.ZstdCompressor(); compressed_data = cctx.compress(data)`.