pydicom

pydicom is a skill for Claude Code, Codex from K-Dense-AI/scientific-agent-skills. It costs 52 tokens per session (4,593 once invoked), scanned A, original, MIT.

A Python toolkit for reading, inspecting, writing, and transforming DICOM files, the standard format used for medical images and their associated data. It can also process pixel data and review datasets for possible de-identification issues.

In plain words
What is it for?
Use it to inspect local DICOM files, convert or process pixel data, handle compressed and multi-frame images, work with JSON representations, and prepare privacy reviews.
Why use it?
It provides controlled access to medical-image metadata and pixels while highlighting that filenames, private fields, overlays, and images may contain protected health information.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it to inspect local DICOM files, convert or process pixel data, handle compressed and multi-frame images, work with JSON representations, and prepare privacy reviews.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/k-dense-ai/scientific-agent-skills/pydicom
About the project

Scientific Agent Skills is a collection of reusable procedures that give AI agents capabilities for scientific research across areas such as biology, chemistry, medicine, and drug discovery. It is used by researchers and by people building AI scientist workflows with compatible coding agents. The catalogue contains many of the project's skills and supporting instructions.

K-Dense-AI/scientific-agent-skills · 54,777 stars · on GitHub · arxiv.org

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add K-Dense-AI/scientific-agent-skills --skill pydicom
Clone the repo
git clone --depth 1 https://github.com/K-Dense-AI/scientific-agent-skills

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for pydicom

README.md
[![agentmods](https://agentmods.dev/badge/skills/k-dense-ai/scientific-agent-skills/pydicom/github.svg)](https://agentmods.dev/skills/k-dense-ai/scientific-agent-skills/pydicom)
Your own site
<a href="https://agentmods.dev/skills/k-dense-ai/scientific-agent-skills/pydicom"><img src="https://agentmods.dev/badge/skills/k-dense-ai/scientific-agent-skills/pydicom/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for pydicom

Your own site · 80×15
<a href="https://agentmods.dev/skills/k-dense-ai/scientific-agent-skills/pydicom"><img src="https://agentmods.dev/badge/skills/k-dense-ai/scientific-agent-skills/pydicom.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 52 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 4,593 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • Socket pass 2 Oct 2026
  • Snyk pass 2 Oct 2026
  • NVIDIA SkillSpector warn 7 Sept 2026
SkillSpector: 1 finding, up to medium

These are SkillSpector’s own severities. On a checked sample its high-severity flags on skills were ~96% false positives — a documented command, a public API, a “never do X” rule — so we show them as a caution to read, not a verdict. Why →

  • medium Excessive Agency · line 295
    Skill enables autonomous high-impact decisions without human-in-the-loop verification. Critical operations (destructive commands, financial transactions, data deletion) should require explicit user confirmation.
    Fix: Add human-in-the-loop confirmation for destructive, irreversible, or high-impact operations. Never auto-execute commands that modify files, send data, or alter system state.
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00052 $0.04593
Opus 5.5 $0.00021 $0.01837
Sonnet 5.5 $0.00010 $0.00919
Haiku 4.5 $0.00005 $0.00459

Measured 25d ago against content hash e42c35688a3d, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

pydicom scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 25d ago.

The scan reads SKILL.md. This mod also ships 10 executable files (scripts/__init__.py, scripts/_common.py, scripts/anonymize_dicom.py, …), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

Origin

Copies of this mod

1 near-identical copy found in the catalogue:

  • pydicom — 100% identical, 66 lines differ
skills/pydicom/SKILL.md · 429 lines

How it starts

The opening of the file, as written. The whole thing — 429 lines — stays where its author put it; the contents beside it link to each section on GitHub.

pydicom

Use pydicom for DICOM dataset I/O and pixel processing. Version 3.0.2 is the current stable release reviewed here. It fixes CVE-2026-32711, a crafted DICOMDIR path-traversal issue. pydicom 3.0.2 declares Python >=3.10; its bundled DICOM dictionary is 2024c; the current DICOM Standard reviewed here is 2026d. No PACS, DIMSE, DICOMweb endpoint, or authenticated service is exercised by this local-file skill.

Mandatory safety boundary

  • Work only with local data that the user is authorized to access.
  • DICOM metadata, file names, private elements, overlays, structured content, and pixels may contain protected health information (PHI).
  • Never print Dataset, export full metadata/JSON, or log element values by default. Use a documented allowlist and aggregate output.
  • pydicom is a general DICOM framework, not a diagnostic viewer. Pixel output, validation, conversion, and plugin availability are not diagnostic claims.
  • De-identification is profile-, purpose-, recipient-, jurisdiction-, and threat-context-specific. It requires privacy/DICOM expert verification.
  • Never claim that a tag-removal script is DICOM PS3.15, HIPAA, GDPR, or other compliance. Preserve originals and audit derived outputs.
  • Treat deterministic pseudonymization keys and UID maps as re-identification secrets: use least privilege and encrypted/managed secret storage, never commit, sync, log, or share them with derivatives, and define backup, rotation, revocation, and destruction procedures. A leaked key invalidates the intended separation; rotation also changes deterministic mappings.
  • Set explicit input-file, file-count, frame-count, decoded-byte, and output limits before parsing untrusted or unusually large datasets.

Installation

Create or activate an isolated environment, then install the reviewed release (the pixel-stack pins below require Python 3.12+ because of NumPy):

uv pip install "pydicom==3.0.2"

Uncompressed pixel arrays and image rendering:

Read the full file on GitHub · 429 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 25d ago Changed · +22 lines · -4 tokens per session e42c35688a3d
  2. 26d ago Changed · +8 lines 217d0a040765
  3. 1mo ago First seen · 399 lines · 56 tokens per session scan A 3c8d3a5880d5

Subscribe to this mod's changes

pydicom is a skill published in the GitHub repository K-Dense-AI/scientific-agent-skills (54,777 stars, last pushed today), licensed MIT. It adds 52 tokens to every session and 4,593 once invoked, about $0.0002 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.

Related

Other skills, from other repositories

digital-twin-discharge-drafter

Use when drafting patient discharge summaries, creating personalized discharge instructions, simulating post-discharge outcomes, reducing hospital readmissions, or optimizing care transitions. Generates AI-enhanced discharge documentation with digital twin predictions for improved patient safety.

aipoch/medical-research-skills · 53 tokens

discharge-summary-writer

Generate hospital discharge summaries from admission data, hospital course, diagnoses, procedures, and follow-up plans; use when a structured discharge document is required from clinical notes.

aipoch/medical-research-skills · 38 tokens

paper-figure

Generate publication-quality figures and tables from experiment results. Use when user says "plot this", "make a figure", "generate figures", "paper figures", or needs plots for a paper. Also invoked by /auto's Ledger Figures hook to produce per-claim figures embedded into CLAIMSLEDGER.md.

zjunlp/Mechanist · 68 tokens

ape-write-paper

Writes a polished, standard two-column research paper (LaTeX to PDF) from any source material -- code, docs, experiment logs, benchmark files, notes -- optimising for correctness, readability, structure, figures, tables and references. Supports both standalone papers and conference templates (ACM SIGMOD/VLDB, IEEE…

arpitbbhayani/ape-skills · 125 tokens

LaTeX工具

A tool for creating, compiling, and checking mathematical modelling papers written in LaTeX, a document system often used for technical writing.

XiaoMaColtAI/math-modeling-skill · 46 tokens

thesis-consistency-audit

A consistency audit for quantitative master’s and doctoral theses in management, finance, or strategy. It checks whether numbers, tables, analyses, and claims agree, and can inspect hidden author information in office documents.

Nero1688/claude-academic-skills · 500 tokens