Datasets:
The dataset viewer is not available for this dataset.
Error code: ConfigNamesError
Exception: RuntimeError
Message: Dataset scripts are no longer supported, but found MedVision.py
Traceback: Traceback (most recent call last):
File "/src/services/worker/src/worker/job_runners/dataset/config_names.py", line 66, in compute_config_names_response
config_names = get_dataset_config_names(
^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/datasets/inspect.py", line 161, in get_dataset_config_names
dataset_module = dataset_module_factory(
^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/datasets/load.py", line 1031, in dataset_module_factory
raise e1 from None
File "/usr/local/lib/python3.12/site-packages/datasets/load.py", line 989, in dataset_module_factory
raise RuntimeError(f"Dataset scripts are no longer supported, but found {filename}")
RuntimeError: Dataset scripts are no longer supported, but found MedVision.pyNeed help to make the dataset viewer work? Make sure to review how to configure the dataset viewer, and open a discussion for direct support.
About
MedVision, a large-scale, multi-anatomy, multi-modality dataset for quantitative medical image analysis.
π Project: [to be updated]
π§π»βπ» Code: https://github.com/YongchengYAO/MedVision
π©» Huggingface Dataset: YongchengYAO/MedVision
News
- [Oct 8, 2025] π Release MedVision dataset v1.0.0
TODO
- Add preprint, project page
- Add instructions on how to prepare the SKM-TEA and ToothFairy2 datasets
- Add tutorial on how to expand the dataset
Datasets
π The MedVision dataset consists of public medical images and quantitative annotations from this study. MRI: Magnetic Resonance Imaging; CT: Computed Tomography; PET: positron emission tomography; US: Ultrasound; b-box: bounding box; T/L: tumor/lesion size; A/D: angle/distance; HF: HuggingFace; GC: Grand-Challenge; * redistributed.
| Dataset | Anatomy | Modality | Annotation | Availability | Source | # Sample (Train/Test) | Status | ||
|---|---|---|---|---|---|---|---|---|---|
| b-box | T/L | A/D | |||||||
| AbdomenAtlas | abdomen | CT | b-box | open | HF | 6.8 / 2.9M | 0 | 0 | β |
| AbdomenCT-1K | abdomen | CT | b-box | open | Zenodo | 0.7 / 0.3M | 0 | 0 | β |
| ACDC | heart | MRI | b-box | open | HF*, others | 9.5 / 4.8K | 0 | 0 | β |
| AMOS22 | abdomen | CT, MRI | b-box | open | Zenodo | 0.8 / 0.3M | 0 | 0 | β |
| autoPEI-III | whole body | CT, PET | b-box, T/L | open | HF*, others | 22 / 9.7K | 0.5 / 0.2K | 0 | β |
| BCV15 | abdomen | CT | b-box | open | HF*, Synapse | 71 / 30K | 0 | 0 | β |
| BraTS24 | brain | MRI | b-box, T/L | open | HF*, Synapse | 0.8 / 0.3M | 7.9 / 3.1K | 0 | β |
| CAMUS | heart | US | b-box | open | HF*, others | 0.7 / 0.3M | 0 | 0 | β |
| Ceph-Bio-400 | head and neck | X-ray | b-box, A/D | open | HF*, others | 0 | 0 | 5.3 / 2.3K | β |
| CrossModDA | brain | MRI | b-box | open | HF*, Zenodo | 3.0 / 1.0K | 0 | 0 | β |
| FeTA24 | fetal brain | MRI | b-box, A/D | registration | Synapse | 34 / 15K | 0 | 0.2 / 0.1K | β |
| FLARE22 | abdomen | CT | b-box | open | HF*, others | 72 / 33K | 0 | 0 | β |
| HNTSMRG24 | head and neck | MRI | b-box, T/L | open | Zenodo | 18 / 6.6K | 1.0 / 0.4K | 0 | β |
| ISLES24 | brain | MRI | b-box | open | HF*, GC | 7.3 / 2.5K | 0 | 0 | β |
| KiPA22 | kidney | CT | b-box, T/L | open | HF*, GC | 26 / 11K | 2.1 / 1.0K | 0 | β |
| KiTS23 | kidney | CT | b-box, T/L | open | HF*, GC | 80 / 35K | 5.9 / 2.6K | 0 | β |
| MSD | multiple | CT, MRI | b-box, T/L | open | others | 0.2 / 0.1M | 5.3 / 2.2K | 0 | β |
| OAIZIB-CM | knee | MRI | b-box | open | HF | 0.5 / 0.2M | 0 | 0 | β |
| SKM-TEA | knee | MRI | b-box | registration | others | 0.2 / 0.1M | 0 | 0 | β |
| ToothFairy2 | tooth | CT | b-box | registration | others | 1.0 / 0.4M | 0 | 0 | β |
| TopCoW24 | brain | CT, MRI | b-box | open | HF*, Zenodo | 43 / 20K | 0 | 0 | β |
| TotalSegmentator | multiple | CT, MRI | b-box | open | HF*, Zenodo | 9.6 / 4.0M | 0 | 0 | β |
| Total | 22 / 9.2M | 23 / 9.6K | 5.6 / 2.4K |
β οΈ For the following datasets, which do not allow redistribution, you need to apply for access from data owners, (optionally) upload to your private HF dataset repo, and set corresponding environment variables.
| Dataset | Source | Host Platform | Env Var |
|---|---|---|---|
| FeTA24 | https://www.synapse.org/Synapse:syn25649159/wiki/610007 | Synapse | SYNAPSE_TOKEN |
| SKM-TEA | https://aimi.stanford.edu/datasets/skm-tea-knee-mri | Huggingface | MedVision_SKMTEA_HF_ID |
| ToothFairy2 | https://ditto.ing.unimore.it/toothfairy2/ | Huggingface | MedVision_ToothFairy2_HF_ID |
π For SKM-TEA and ToothFairy2, you need to process the raw data and upload the preprocessed data to your private HF dataset repo. To use HF private dataset, you need to set HF_TOKEN and login with hf auth login --token $HF_TOKEN --add-to-git-credential
Requirement
π Note: trust_remote_code is no longer supported in datasets>=4.0.0, install dataset with pip install datasets==3.6.0
Use
import os
from datasets import load_dataset
# Set data folder
os.environ["MedVision_DATA_DIR"] = <your/data/folder>
# Pick a dataset config name and split
config = <config-name>
split_name = "test", # use "test" for testing set config; use "train" for training set config
# Get dataset
ds = load_dataset(
"YongchengYAO/MedVision",
name=config,
trust_remote_code=True,
split=split_name,
)
π List of config names in info/
Environment Variables
# Set where data will be saved, requires ~1T for the complete dataset
export MedVision_DATA_DIR=<your/data/folder>
# Force download and process raw images, default to "False"
export MedVision_FORCE_DOWNLOAD_DATA="False"
# Force install dataset codebase, default to "False"
export MedVision_FORCE_INSTALL_CODE="False"
Advanced Usage
The dataset codebase medvision_ds can be used to scale the dataset, including adding new annotation types and datasets.
π οΈ Install
pip install "git+https://huggingface.co/datasets/YongchengYAO/MedVision.git#subdirectory=src"
pip show medvision_ds
or
# First, install the benchmark codebase: medvision_bm
pip install "git+https://github.com/YongchengYAO/MedVision.git"
# Install the dataset codebase: medvision_ds
pip install huggingface_hub
# NOTE: replace <local-data-folder>
python -c "from medvision_bm.utils import install_medvision_ds; install_medvision_ds(data_dir='<local-data-folder>')"
π§π»βπ» Use utility functions for image processing
from medvision_ds.utils.data_conversion import (
convert_nrrd_to_nifti,
convert_mha_to_nifti,
convert_nii_to_niigz,
convert_bmp_to_niigz,
copy_img_header_to_mask,
reorient_niigz_RASplus_batch_inplace,
)
from medvision_ds.utils.preprocess_utils import (
split_4d_nifti,
)
π©πΌβπ»Examples of dataset scaling:
Setup automatic data processing pipeline
- Download preprocessed data from HF: medvision_ds/datasets/OAIZIB_CM/download.py
- Download and processed data from source: medvision_ds/datasets/BraTS24/download_raw.py
Prepare annotations
Generate b-box annotations from segmentation masks:
Generate tumor/lesion size (TL) annotations from segmentation masks:
Generate angle/distance (AD) annotations from landmarks:
- Downloads last month
- 1,236
