Medical Image to Patient-Specific Reduced-Order Hemodynamic Model Simulation in Minutes
MIROS takes a CT or MR angiogram, or a vessel surface you already have, and turns it into patient-specific 0D and 1D blood-flow simulations: segmentation with SeqSeg, centerlines, the reduced-order models, outlet boundary conditions tuned to the flow split and pressures you ask for, the svZeroDSolver and svOneDSolver runs, and the results in mmHg. One window or one command, every input in one file, and only what changed is recomputed. No SimVascular installation is needed.
(Manuscript in preparation.)
image ──segment──▶ surface ──preprocess──▶ caps ──rom_model──▶ centerlines, 0D model
│
results/0D, results/1D ◀──extract── sim_0d, sim_1d ◀──tune──┘ RCR boundary conditions
Python 3.10 to 3.12 on Linux, macOS or Windows.
git clone https://github.com/BryannGan/MIROS.git && cd MIROS
python -m venv .venv && source .venv/bin/activate # Windows PowerShell: .venv\Scripts\Activate.ps1
pip install -e ".[all]" # MIROS, the window, SeqSeg (pulls torch, about 2 GB)
miros install all # the two SimVascular solvers and the SeqSeg weights
miros doctor # what is there, what is missing, and how to get itmiros install … |
Gets | From |
|---|---|---|
pysvzerod |
the 0D solver (svZeroDSolver), for the tuning and sim_0d |
a prebuilt wheel in this repository's solvers release, else a source build |
onedsolver |
the 1D solver (svOneDSolver), for sim_1d, optional |
a prebuilt executable in the same release, into ~/.miros/bin |
seqseg |
SeqSeg with a torch for your GPU, and the aorta_ct weights |
PyPI and Zenodo |
The install guide has each step by hand as well, per operating system,
and what miros doctor prints when everything is in place.
miros run examples/aortaThe bundled aortic arch goes from surface to tuned 0D and 1D results in about two minutes.
Results land in examples/aorta/results/0D and results/1D. Run it again and nothing happens:
every stage records what it read, and only stale stages re-run.
In the window, from an image or a surface:
miros guiSeven steps, the 3D model always on the left: Segment (image, seeds, SeqSeg) → Outlets (approve the cuts that open the vessel ends) → Model (or start here from a clipped surface) → Inflow (draw or load one cardiac cycle) → Targets (name the caps, flow shares, pressure) → Run (live log, progress, Stop) → Results.
On the command line, from a clipped surface:
miros init ~/cases/patient01 --surface surface.vtp --inflow inflow.flow # writes a commented case.yaml
miros setup ~/cases/patient01 # or edit case.yaml: flow split, pressure targets
miros run ~/cases/patient01| Page | What is in it |
|---|---|
| Install | every dependency, per operating system, and how to check them |
| The window | the seven steps of miros gui |
| Commands | miros doctor / init / run / status / models / gui / setup / show / inflow, the stages, the library |
| The case file | every option in case.yaml, with the full template |
| From an image | SeqSeg, seeds, the pretrained models, how the vessel ends are opened |
| Boundary-condition tuning | how the RCR values are found, and which targets are reachable |
| Troubleshooting | the messages you may see and what they mean |
| Development | tests, continuous integration, validation against SimVascular, layout |
Working on the code with an AI agent? AGENTS.md is written for it.
MIROS builds on SimVascular, svZeroDSolver, svOneDSolver and SeqSeg. Please cite them with it (see CITATION.cff):
- Updegrove A. et al., SimVascular: An Open Source Pipeline for Cardiovascular Simulation, Ann Biomed Eng 2017.
- Pfaller M.R. et al., Automated generation of 0D and 1D reduced-order models of patient-specific blood flow, Int J Numer Meth Biomed Eng 2022.
- Sveinsson Cepero N. & Shadden S.C., SeqSeg: Learning Local Segments for Automatic Vascular Model Construction, Ann Biomed Eng 2024. https://doi.org/10.1007/s10439-024-03611-z
MIT (see LICENSE). The vendored SimVascular modules under miros/rom and
miros/rom_extract keep their own permissive license, reproduced in every file.