Guides

Dataset catalog

Public package status: the Python distributions and desktop installers are not released yet. These pages document an evolving interface, not currently usable install artifacts. View release status.

MedOtter ships a committed catalog of 130 public radiology and imaging datasets — CT, MRI, endoscopy, dermoscopy, histopathology, and more. The catalog layer (list_datasets, describe, DatasetInfo) is fully torch-free: it reads a JSON file bundled with the package, so it works with no GPU, no network access, and no ML dependencies installed.

Listing and filtering datasets

def list_datasets(modality=None, anatomy=None, task=None, has_video=None) -> list[DatasetInfo]

modality, anatomy, and task are case-insensitive substring matches against free-text catalog fields — a dataset’s modality might be recorded as "CT, MRI" or its anatomy as "abdomen, liver", so filtering with a short substring is usually what you want. has_video is an exact boolean match (whether the dataset is also registered as a video-style loader that returns frame sequences — true for literal video captures like endoscopy and laparoscopy, as well as some 3D volumetric datasets exposed as slice sequences).

import medotter as mo

mo.list_datasets(anatomy="liver")           # substring match: 11 datasets
mo.list_datasets(modality="CT, MRI")        # exact free-text match: HANSeg, MSD
mo.list_datasets(has_video=False)           # single-image (non-video) datasets only

Each call returns a list[DatasetInfo], sorted by name. With no arguments, mo.list_datasets() returns all 130 entries.

Looking up one dataset

def describe(name: str) -> DatasetInfo

name must be the dataset’s exact registry key — catalog keys are case-sensitive ("ACDC", not "acdc"). An unknown name raises KeyError with a “did you mean” hint when a close match exists:

mo.describe("ACDC")
# DatasetInfo(name='ACDC', modality='MRI', anatomy='heart, cardiac',
#             task='organ, cardiac', n_classes=4, ...)

mo.describe("acdc")
# KeyError: unknown dataset 'acdc'. Did you mean: ACDC? Use
#           medotter.list_datasets() to see all 130.

DatasetInfo fields

FieldTypeMeaning
namestrExact registry key, e.g. "ACDC".
modalitystr | NoneFree-text imaging modality, e.g. "CT", "CT, MRI".
anatomystr | NoneFree-text anatomical region(s), e.g. "abdomen, liver".
taskstr | NoneFree-text task description, e.g. "organ, cardiac".
n_classesint | NoneNumber of label classes, including background if named.
class_nameslist[str] | NoneClass names in label-index order (index 0 is conventionally background).
class_labelsdict[int, str] | NoneExplicit {label_id: name} map — the authoritative source for LabelSchema.from_catalog.
background_idint | NoneThe label id treated as background, when known. May be None.
ignore_idslist[int] | NoneLabel ids that should not be scored (e.g. “unannotated” regions).
input_channelsint | NoneExpected image channel count.
has_videoboolWhether the dataset is also registered as a video-style loader.
hf_repostr | NoneHugging Face dataset repo backing this entry, if any.
sourcestr | NoneHuman-readable source/provenance note.
cardstr | NonePath to the dataset’s knowledge card, if one exists.

Common errors