pydicom

Read, write, modify, and anonymize DICOM datasets in Python.

18|1|Updated Dec 27, 2025
One-click install
npx skills add https://github.com/LogauaEngstrom/claude-scientific-skills --skill pydicom-logauaengstrom
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: pydicom
Source: https://github.com/LogauaEngstrom/claude-scientific-skills/tree/main/scientific-skills/pydicom
Command: npx skills add https://github.com/LogauaEngstrom/claude-scientific-skills --skill pydicom-logauaengstrom

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires pydicom, numpy, pillow, and includes scripts (resource) and references (resource) components.

What problem does it solve?

Python tooling to read, write, modify, and anonymize DICOM files, enabling safe handling of medical imaging data and metadata workflow automation.

Core Features & Use Cases

  • Read, write, and modify DICOM datasets including metadata and pixel data
  • Anonymize protected health information (PHI) while preserving image data
  • Convert DICOM images to common formats and handle multi-frame/color images
  • Extract and inspect DICOM metadata for clinical research and PACS workflows
  • Support for compressed transfer syntaxes and pixel data handling in Python

Quick Start

Load a DICOM file and extract its pixel data for visualization.

Frequently Asked Questions about pydicom

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I read DICOM files and extract pixel data in Python?

You can read DICOM files and extract pixel data in Python by loading datasets to access metadata and pixel arrays, handling multi-frame and color images for visualization and processing workflows.

What is the best way to anonymize DICOM files while preserving image data?

Anonymizing DICOM files involves removing protected health information from metadata while keeping the original pixel data intact for safe medical imaging data sharing and research.

Can I convert DICOM images to common image formats like PNG or JPEG?

Yes, converting DICOM images to common formats is possible by extracting pixel data and using image processing libraries to export standard image files for visualization.

Does Python support handling compressed DICOM transfer syntaxes?

Python supports compressed DICOM transfer syntaxes by parsing various compression formats during file reading, allowing access to pixel data across different medical imaging workflows.

How do I modify DICOM metadata for PACS integration workflows?

Modifying DICOM metadata for PACS workflows requires loading datasets, accessing specific metadata tags, updating values, and writing changes back to maintain dataset integrity.

What limitations exist when processing multi-frame DICOM images in Python?

Processing multi-frame DICOM images requires careful pixel data handling for frame extraction and color management, especially when dealing with compressed transfer syntaxes and large datasets.