Image transformation, compression, and decompression codecs
Project description
Imagecodecs is a Python library that provides block-oriented, in-memory buffer transformation, compression, and decompression functions for use in the tifffile, czifile, and other scientific imaging modules.
Decode and/or encode functions are currently implemented for Zlib DEFLATE, ZStandard (ZSTD), Blosc, LZMA, BZ2, LZ4, LZW, LZF, ZFP, NPY, PNG, WebP, JPEG 8-bit, JPEG 12-bit, JPEG SOF3, JPEG LS, JPEG 2000, JPEG XR, PackBits, Packed Integers, Delta, XOR Delta, Floating Point Predictor, and Bitorder reversal.
- Author:
- Organization:
Laboratory for Fluorescence Dynamics. University of California, Irvine
- License:
3-clause BSD
- Version:
2019.11.5
Requirements
This release has been tested with the following requirements and dependencies (other versions may work):
libjpeg-turbo 2.0.3 (8 and 12-bit)
Required for testing (other versions may work):
Notes
Imagecodecs is currently developed, built, and tested on Windows only.
The API is not stable yet and might change between revisions.
Works on little-endian platforms only.
Python 2.7 and 32-bit are deprecated.
The Microsoft Visual C++ Redistributable Packages are required on Windows.
Refer to the imagecodecs/licenses folder for 3rd party library licenses.
This software is based in part on the work of the Independent JPEG Group.
This software includes modified versions of dcm2niix’s jpg_0XC3.cpp and openjpeg’s color.c.
To install the requirements for building imagecodecs from source code on current Debian based Linux distributions, run:
$ sudo apt-get install build-essential python3-dev cython3 python3-setuptools python3-pip python3-wheel python3-numpy libz-dev libblosc-dev liblzma-dev liblz4-dev libzstd-dev libpng-dev libwebp-dev libbz2-dev libopenjp2-7-dev libjpeg62-turbo-dev libjxr-dev liblcms2-dev libtiff-dev
The imagecodecs package can be challenging to build from source code. Consider using the imagecodecs-lite package instead, which does not depend on external third-party C libraries and provides a subset of image codecs for the tifffile library: LZW, PackBits, Delta, XOR Delta, Packed Integers, Floating Point Predictor, and Bitorder reversal.
Other Python packages providing imaging or compression codecs:
Revisions
- 2019.11.5
Rebuild with updated dependencies.
- 2019.5.22
Pass 2701 tests. Add optional YCbCr chroma subsampling to JPEG encoder. Add default reversible mode to ZFP encoder. Add imread and imwrite helper functions.
- 2019.4.20
Fix setup requirements.
- 2019.2.22
Move codecs without 3rd-party C library dependencies to imagecodecs_lite.
- 2019.2.20
Rebuild with updated dependencies.
- 2019.1.20
Add more pixel formats to JPEG XR codec. Add JPEG XR encoder.
- 2019.1.14
Add ZFP codecs via zfp library (WIP). Add numpy NPY and NPZ codecs. Fix some static codechecker errors.
- 2019.1.1
Update copyright year. Do not install package if Cython extension fails to build. Fix compiler warnings.
- 2018.12.16
Reallocate LZW buffer on demand. Ignore integer type output arguments for codecs returning images.
- 2018.12.12
Enable decoding of subsampled J2K images via conversion to RGB. Enable decoding of large JPEG using patched libjpeg-turbo. Switch to Cython 0.29, language_level=3.
- 2018.12.1
Add J2K encoder (WIP). Use ZStd content size 1 MB if it cannot be determined. Use logging.warning instead of warnings.warn or print.
- 2018.11.8
Decode LSB style LZW. Fix last byte not written by LZW decoder (bug fix). Permit unknown colorspaces in JPEG codecs (e.g. CFA used in TIFF).
- 2018.10.30
Add JPEG 8-bit and 12-bit encoders. Improve color space handling in JPEG codecs.
- 2018.10.28
Rename jpeg0xc3 to jpegsof3. Add JPEG LS codec via libcharls. Fix missing alpha values in jxr_decode. Fix decoding JPEG SOF3 with multiple DHTs.
- 2018.10.22
Add Blosc codecs via libblosc.
- 2018.10.21
Builds on Ubuntu 18.04 WSL. Include liblzf in srcdist. Do not require CreateDecoderFromBytes patch to jxrlib.
- 2018.10.18
Improve jpeg_decode wrapper.
- 2018.10.17
Add JPEG SOF3 decoder based on jpg_0XC3.cpp.
- 2018.10.10
Add PNG codecs via libpng. Add option to specify output colorspace in JPEG decoder. Fix Delta codec for floating point numbers. Fix XOR Delta codecs.
- 2018.9.30
Add LZF codecs via liblzf.
- 2018.9.22
Add WebP codecs via libwebp.
- 2018.8.29
Add PackBits encoder.
- 2018.8.22
Add link library version information. Add option to specify size of LZW buffer. Add JPEG 2000 decoder via openjpeg. Add XOR Delta codec.
- 2018.8.16
Link to libjpeg-turbo. Support Python 2.7 and Visual Studio 2008.
- 2018.8.10
Initial alpha release. Add LZW, PackBits, PackInts and FloatPred decoders from tifffile.c module. Add JPEG and JPEG XR decoders from czifile.pyx module.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distributions
Hashes for imagecodecs-2019.11.5-pp372-pp372-win32.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | f84f041552e3baa78672c16e795f2d419b1453a67bda0d7722e593cffa6a227c |
|
MD5 | 561fef29b13dddd8f0f56c40ec7baf1a |
|
BLAKE2b-256 | 46f8acad696c85949b20734144eb56b0a731a20aea7cadc6889805fd0cc443aa |
Hashes for imagecodecs-2019.11.5-pp272-pypy_41-win32.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | a6ed7c7464dc78ae099d077ab1e207768f52523232feef5b9266a39da987e9e0 |
|
MD5 | 4509a310be66ce330026b69c84289a74 |
|
BLAKE2b-256 | 37a698e32bf078f3154fb8373c532e65158c143fb07349ea0db12222bfbadea6 |
Hashes for imagecodecs-2019.11.5-cp38-cp38-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | ff75b73c0676a8cba437e168c2aeafe1bc418f69a5e00703752d0f4265a14729 |
|
MD5 | 3706c280b9d8608552551c1630550041 |
|
BLAKE2b-256 | 5ae3980c84fe5612425e377aa600a0e6318eb67aeeb505a3ff73cf58efefc600 |
Hashes for imagecodecs-2019.11.5-cp38-cp38-win32.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | bf0ff099790e6da362902402d324432ae826257be2d006789f0cbfe3e032d569 |
|
MD5 | 32f672cf3de31b07527b88852fed68fe |
|
BLAKE2b-256 | 6cc2df2c67fdb7ae70f3ecab485d20f3915eb098f62203794cd89ce8bd7700cd |
Hashes for imagecodecs-2019.11.5-cp37-cp37m-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 73d1727249057cac9a60c6b5126316197a27242e701f790f89d93b66fc2adb2b |
|
MD5 | 1a8c94f044c693baa1c1bf1e1a3867b0 |
|
BLAKE2b-256 | a7bc25b61abfa7b3fe6af5ecb42ec41e84601e3649817062dcafbdd4c58cea94 |
Hashes for imagecodecs-2019.11.5-cp37-cp37m-win32.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 82266288b5f0c67e2402068cf57d8d11cf65c36413cb455861e46a07123d7c20 |
|
MD5 | 72aa351dbb64235adfb87fda24313d61 |
|
BLAKE2b-256 | a395d05758d322600bb5bc5c724131801456a2b42bb1caad51902c4c185e5406 |
Hashes for imagecodecs-2019.11.5-cp36-cp36m-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 307d62fe210c27830266f22472e556b38797a0bd48058a31b95f53a2eb4f3a65 |
|
MD5 | 68d6077ace30c4738ef03d8f4bc54c86 |
|
BLAKE2b-256 | 4e8b090b8ba2eb98731ec730ccefe300b5dbdfd5ec3d9688084087e8ad3c34ea |
Hashes for imagecodecs-2019.11.5-cp36-cp36m-win32.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 62d123fc415d9fad27590c39b2a2a521f62e5b50592f7f804e8fc0f3eb947c2e |
|
MD5 | 5fef74e79f947cd44a476fa81dc95086 |
|
BLAKE2b-256 | 56d8fa8ef08a03cecf557f0d500494fd7860325642cb07b3b5d49e08439890c3 |
Hashes for imagecodecs-2019.11.5-cp35-cp35m-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | a80888074ad34d6a1cfa00dc810fe6a1b2fe8b4e79bce7b208995fa9f7c85fff |
|
MD5 | 2183dd035e286ba5ffe2d25ae21fe026 |
|
BLAKE2b-256 | f100407b853a7ffb34c1124ff0e7f463e386a7a9d58a59c29d887413d92dce46 |
Hashes for imagecodecs-2019.11.5-cp35-cp35m-win32.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 82b05037ed47b2887754e107b1ca1a69fb4b290dc8ffb7de6b0ede750664297e |
|
MD5 | e67abe775f0fbbd7e7b568d3b0e37c58 |
|
BLAKE2b-256 | 88268b7c34098b31f6b1b64c88f59455722d979fa17c77ff6256335281de1fa6 |
Hashes for imagecodecs-2019.11.5-cp27-cp27m-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 7b9a0b73e0103c2c8e52e6821d7381a85c3db483d15c4da6b8ddf1d4c8154716 |
|
MD5 | e1dfd919031ede19dadbb1bf46033fc2 |
|
BLAKE2b-256 | 7b54fb9c3f8796142aa7d1cbbb65cca0fd2efefda92be93ac70c5309737cd16c |
Hashes for imagecodecs-2019.11.5-cp27-cp27m-win32.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 3fa2f2526c21eee3809536efacc3d6b35557882dae2d12f33e05f980c4b72fcf |
|
MD5 | f43c4d6a667e9913d8354482a0158201 |
|
BLAKE2b-256 | 98ee2b5550f422bd6307535bfb1bedf2418ae50632adf748396f0e02399cfeaf |