v0.8.0-beta.9
This software is in beta version, which means it is still undergoing testing and development before its official release. It may contain bugs, errors, or incomplete features that could affect its performance and functionality. By using this software, you agree to accept the risks and limitations associated with beta software. We appreciate your feedback and suggestions to help us improve this software, but we do not guarantee that we will implement them or that the software will meet your expectations. Please use this software at your own discretion and responsibility.
Key Features and Enhancements
- Added pydicom plugin for seamless GPU-accelerated DICOM decoding. The plugin integrates with pydicom's standard workflow, automatically accelerating decoding for supported compressed transfer syntaxes (JPEG, JPEG 2000, JPEG Lossless, HTJ2K).
- Added DICOM compression tools for HTJ2K transcoding and multi-frame conversion. Includes utility functions for batch transcoding DICOM series to HTJ2K compression and converting single-frame series to Enhanced (multi-frame) DICOM format with optional simultaneous compression.
- PNG CPU encoder backend now supports quality value in range from 0 (lowest compression ratio, fastest) to 9 (highest compression ratio, slowest), if quality type is
NVIMGCODEC_QUALITY_TYPE_LOSSLESS. - Added conversion from RGB to grayscale in OpenCV encoder.
- Added TIFF CodeStream offset support, allowing parsing from a custom IFD offset (
bitstream_offset). - Added
subifd_offsetsfield to CodeStreams. This allows parsing and decoding SubIFDs throughbitstream_offsetAPI. - Added TIFF pagination support via
limit_imagesandnext_bitstream_offsetto page through large multi-image TIFFs. - Added
TIFF_TAG_LISTmetadata kind to enumerate available TIFF tag IDs. Non-existent tag lookups now returnNoneinstead of raising. - Breaking change:
nvimgcodecCodeStreamCreateFromFileandnvimgcodecCodeStreamCreateFromHostMemnow take an additionalcode_stream_viewparameter (nullable). This can be used to specifybitstream_offsetandlimit_imagesat creation time. - CUDA streams are now managed with a shared pool and round-robin thread assignment. The default is num_streams = num_threads. This can be changed with the
NVIMGCODEC_DEFAULT_NUM_CUDA_STREAMSenvironment variable or:num_cuda_streams=Noption (1 to num_threads). - Reduced overhead of internal GPU stream synchronization.
- Implemented early library loading and version checking for nvJPEG, nvJPEG2000, and nvTIFF extensions. Libraries are now loaded at plugin registration time (not at first decode/encode), with minimum version requirements enforced. This ensures better error detection and provides early feedback when library dependencies are unavailable or outdated. Minimum versions required: nvJPEG (CUDA version-dependent), nvJPEG2000 0.8.0+, and nvTIFF 0.4.0+. We advise using latest versions to get full feature support.
- Breaking change: Encoding JPEG2000 on GPU is no longer supported with nvJPEG2000 v0.8.1 or older. Please update to v0.9.0 or newer.
- Added :doc:
sliding window decoding with tile cache <samples/sliding_window_tile_cache>example notebook, demonstrating how to scan a large tiled image with a sliding window while caching already-decoded tiles and batch-decoding only the new tiles needed at each step. - JPEG2000 CUDA backend can now encode RGB image with Alpha channel and YUV image.
Fixed Issues
- Fixed extension auto-discovery to correctly locate extensions when the library is installed under
lib/orbin/directories in addition tolib64/(e.g. conda environments on Linux, standard system installs). - Fixed issue with nvTIFF encoder not supporting precision 0 (full-precision of the data type) value.
- Fixed precision handling for signed data types.
- Fixed DLPack export so that it gives co-ownership of the underlying image buffer to the consumer.
- Fixed TIFF parser to support LONG8 (64-bit) dimension tags, with validation to reject dimensions exceeding 32-bit limits.
- Fixed TIFF parser to treat TIFF sample format 0 (uninitialized) as unsigned integer.
- Fixed TIFF grayscale parsing when SamplesPerPixel tag is missing by defaulting to 1.
- Added support for parsing Hamamatsu NDPI images larger than 4Gb
- Improved JPEG2K (JPEG 2000) parser to tolerate slightly malformed but decodable files
- Fixed encoder-created CodeStream so that metadata (e.g.
num_images,get_code_stream_info()) andget_sub_code_stream(image_idx=0)work correctly; previouslynum_imageswas 0 and sub-code-stream creation could fail or assert. - Fixed TIFF decoder when decoding a sub code stream created with only
image_idx(no region), avoiding an assertion in region bounds check. - Fixed Python
CodeStream: callingget_sub_code_stream(idx=0)(invalid kwarg) now raisesTypeErrorwith a clear message instead of aborting; - Fixed a segfault that occurred when passing a GPU-decoded
Imagedirectly to NumPy (e.g.np.array(img)). NumPy now raises a clearRuntimeErrortelling the user to call.cpu()first, instead of crashing. CPU images work correctly and produce a zero-copy NumPy array.