Skip to content

About

No description, website, or topics provided.

Resources

Stars

3 stars

Watchers

1 watching

Forks

Latest commit

 

History

19 Commits

Folders and files

Repository files navigation

What is DicomHTJ2K ?

This is python tool to encode and decode High-Throughput JPEG 2000 (HTJ2K) dicoms. Based on OpenJPH which is written in C++ and openjphpy which is a py wrapper. DicomHTJ2K package coming soon...

Note: This is an experimental repository.

Why use DicomHTJ2K ?

If you want to save storage cost (compression ratio) and not compromise user experience (encode/decode time) htj2k promises to solve both the issues.

Resources

For more resources regarding HTJ2K, please refer to:

Which transfer syntax to use ?

Dicom standards recently introduced new transfer syntax for htj2k encodings link

Transfer Syntax UID Description
1.2.840.10008.1.2.4.201 HTJ2K (Lossless Only)
1.2.840.10008.1.2.4.202 HTJ2K (Lossless RPCL)
1.2.840.10008.1.2.4.203 HTJ2K

How to use ?

from htj2k.compression import DicomHTJ2K

com = DicomHTJ2K("./data/chest_xray.dcm")
com_time = com.compress('RPCL')
print(f"   compression time: {com_time:.3f} secs")

decom_time = com.decompress()
print(f"de-compression time: {decom_time:.3f} secs")

print(f"   compression ratio: {com.compression_ratio:.3f} ")

Note: Currently only works on 8 bit and 16 bit images.

Please contact for more details / discussions / suggestions / improvements / bugs / support on github issues or on [email protected].

About

No description, website, or topics provided.

Resources

Stars

3 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages