--- id: python-gdcm version: "3.2.6" license: Apache-2.0 license_treatment: permissive maintenance: active --- # python-gdcm — Grassroots DICOM runtime libraries License: permissive · Maintenance: active · Downloads: 561.0K/mo ## What it is and what it does python-gdcm is an unofficial Python binding for GDCM, a mature C++ library for working with DICOM (Digital Imaging and Communications in Medicine) files—the standard format for medical imaging data. It lets you read, write, and manipulate DICOM datasets programmatically, handling multiple compression and encoding schemes (JPEG, JPEG 2000, JPEG-LS, RLE, deflated) and providing access to the DICOM standard definitions as XML. The package is distributed as pre-compiled wheels for Python 3.9–3.13 across Linux, macOS, and Windows, eliminating the need to build from source in most cases. It has no runtime dependencies beyond the Python standard library, making it straightforward to integrate into medical imaging pipelines, research workflows, or healthcare IT systems that need to parse or generate DICOM files. Use it for: - Read and extract pixel data and metadata from DICOM medical images in automated workflows. - Convert DICOM files between different transfer syntaxes or compression formats for interoperability. - Build medical imaging applications that need to validate or manipulate DICOM datasets programmatically. - Integrate DICOM file handling into research or clinical data processing pipelines. - Access DICOM standard definitions (Parts 3, 6, 7) as XML for validation or reference. ## Worth the install? AI-flagged interpretation of the facts above — verify before relying. Python wrapper for GDCM (Grassroots DICOM), a C++ library that reads, writes, and manipulates DICOM medical image files with support for multiple transfer syntaxes including JPEG, JPEG 2000, JPEG-LS, RLE, and deflated formats. Yes. python-gdcm is actively maintained, has no security vulnerabilities, supports current Python versions (3.9–3.13), and offers pre-built wheels that minimize install friction. The Apache-2.0 license is permissive. Install it if you need to work with DICOM medical images in Python; the C++ bindings are mature and the library is production-stable. ## Install pip install python-gdcm uv add python-gdcm poetry add python-gdcm ## Installing python-gdcm Before you install: Medium install friction due to compiled C++ bindings; pre-built wheels available for Python 3.9–3.13 on Linux (x86_64, aarch64), macOS (Intel and Apple Silicon), and Windows. Last release 95 days ago; repository actively maintained with recent commits. License in practice: Apache-2.0 permissive license allows commercial and private use with minimal restrictions; suitable for most projects. Quickstart: pip install python-gdcm import gdcm reader = gdcm.ImageReader() reader.SetFileName("dicom_image_file.dcm") ret = reader.Read() Requires Python 3.7 or later; building from source requires CMake, SWIG, a C++ compiler, and patchelf on Linux. Verify before relying: - Performance characteristics and memory footprint for large DICOM datasets or batch processing workflows. - Completeness of DICOM standard support beyond the stated transfer syntaxes and Parts 3, 6, 7. - Stability and API compatibility across minor versions; changelog detail for recent updates. ## Package facts - License: Apache-2.0 (permissive) - Python support: supports_current - Install friction: medium - Maintenance: active - Downloads: 561.0K/month (top 15,000 on PyPI) - Known vulnerabilities: none known ## Tags DICOM file reader python, medical image processing DICOM, GDCM python wrapper, DICOM transfer syntax support, medical imaging library, medical-imaging, dicom, c-bindings [View on SkillFed](https://skillfed.io/packages/python-gdcm) · [View on PyPI](https://pypi.org/project/python-gdcm/)