MRSegmentator-KonfAI
KonfAI-accelerated adaptation of MRSegmentator β multi-organ MRI segmentation (40 structures), built with KonfAI.
π§© Model
| Model | Modality | Labels | Ensemble |
|---|---|---|---|
MRSegmentator |
MRI | 40 | 5 |
3D residual UNet Β· patch [96, 128, 160] Β· resampled to 1.5 mm.
π Usage
pip install mrsegmentator-konfai
mrsegmentator-konfai segment -i input_mr.nii.gz -o output/
- Generic runner:
konfai-apps infer VBoussot/MRSegmentator-KonfAI:MRSegmentator -i input_mr.nii.gz -o output/ - Interactive: SlicerKonfAI β the β Advanced dialog overrides patch size and batch size.
β‘ Performance & VRAM
Same input, the five folds ensembled on both sides (-f 5), same PyTorch build (2.12.1, cu13.0), single NVIDIA RTX PRO 5000 (24 GB), MRSegmentator 2.0.0. Peak RAM = process-tree resident set; peak VRAM = over baseline. Measured with KonfAI's benchmarks/perf/bench_apps.py (2026-09-09).
| Case (voxels) | Tool | Time | Peak RAM | Peak VRAM |
|---|---|---|---|---|
| S (248 Γ 246 Γ 141) | KonfAI | 15 s | 5.2 GB | 18.2 GB |
| Original | 19 s | 7.2 GB | 3.0 GB | |
| M (249 Γ 246 Γ 246) | KonfAI | 21 s | 5.3 GB | 16.3 GB |
| Original | 24 s | 8.5 GB | 3.8 GB | |
| L (512 Γ 512 Γ 531) | KonfAI | 86 s | 6.9 GB | 20.6 GB |
| Original | 143 s | 37.4 GB | 14.9 GB |
1.2β1.7Γ faster, 1.4β5.4Γ less host RAM, the gap widening with the volume. The GPU-resident accumulator trades more VRAM for the speed and low host RAM, while streaming keeps it bounded: on the large case host RAM stays at 6.9 GB where the original grows to 37.4 GB. The default -f 2 ensembles two folds and runs faster than the table. The batch size is auto-selected from your free VRAM; override with --patch-size / --batch-size.
π Links
- π§ Original MRSegmentator: github.com/hhaentze/MRSegmentator
- π§ KonfAI: github.com/vboussot/KonfAI
- π¦ PyPI: mrsegmentator-konfai