Claude Skill MartBrowse skillsWhat is a Skill?
Back to list

histolab (WSI Tile Extraction)

Guides Claude through tissue detection, tile extraction and stain normalization on gigapixel whole slide images using the histolab Python library.

Data & AnalyticsIntermediate33,0303,248AI score 7/10Last updated: Aug 9, 2026

What it does

Provides working recipes for the histolab library so Claude can build digital-pathology preprocessing pipelines:

  • Load slides, inspect properties and pyramid levels, save thumbnails
  • Detect tissue with TissueMask, BiggestTissueBoxMask, or custom masks
  • Pick a tiling strategy: RandomTiler (sampling), GridTiler (full coverage), ScoreTiler (quality-driven, e.g. NucleiScorer)
  • Chain image and morphological filters; apply Macenko/Reinhard stain normalization
  • Preview tile placement with locate_tiles() and visualize masks
  • Troubleshoot no-tiles, background-heavy output, slow extraction, and cross-slide inconsistency

Who it's for

  • Researchers building deep-learning datasets from H&E slides
  • ML engineers standardizing the preprocessing stage of a pathology pipeline
  • Students new to WSIs who need sensible tiler and parameter defaults

Examples

  1. "Extract 200 random 512x512 tiles from this .svs at 80% tissue threshold" → seeded RandomTiler script plus a preview step.
  2. "Stain color varies across my cohort" → shows how to insert MacenkoStainNormalizer into the tile pipeline.
  3. "GridTiler extraction takes hours" → recommends lower pyramid levels, BiggestTissueBoxMask, and tissue_percent tuning.

· · · Install guide · · ·

Install in the Claude app (no terminal)
  1. Download the ZIP with the button below.
  2. In Claude, open Settings → Capabilities and turn on 'Code execution and file creation'. (one time)
  3. Go to Customize → Skills → + → 'Upload a skill' and upload the ZIP.
Download ZIP
Install in Claude Code

Let Claude do it — paste this into Claude Code

Install the skill I found on Claude Skill Mart.
Copy the skills/histolab folder from the GitHub repo K-Dense-AI/scientific-agent-skills into my ~/.claude/skills/histolab/.
When it's done, tell me in one line what this skill can do.

Install with a command instead

git clone https://github.com/K-Dense-AI/scientific-agent-skills.git /tmp/scientific-agent-skills && mkdir -p ~/.claude/skills && cp -r /tmp/scientific-agent-skills/skills/histolab ~/.claude/skills/

This is a third-party skill. Check the source repository before installing.

  1. Install the OpenSlide system libraries first (macOS: brew install openslide, Ubuntu: sudo apt install openslide-tools). Windows is not supported by histolab 0.7.0.
  2. In a Python 3.8–3.11 environment run pip install histolab (add pip install pooch for the bundled TCGA sample slides).
  3. Clone the skill repository: git clone https://github.com/K-Dense-AI/scientific-agent-skills.git
  4. Copy the skill folder into Claude: mkdir -p ~/.claude/skills && cp -r scientific-agent-skills/skills/histolab ~/.claude/skills/
  5. Restart Claude Code and ask something like "use histolab to extract tiles from this slide" to trigger the skill.
  6. Verify the references/ directory came along — the detailed per-topic examples live there.