Visualize velocity image series from a phase contrast magnetic resonance imaging study as a three-dimensional vector field.
Clone the repository
git clone https://github.com/lewinkoon/hemoflow
Change into the project directory
cd hemoflow
Create a virtual environment inside the directory
python -m venv .venv
Activate the previously created virtual environment
.venv\Scripts\activate # on Windows
source .venv/bin/activate # on Unix or MacOS
Install poetry
dependency manager
python -m pip install poetry
Install the required dependencies for the project
poetry install
Create the required file directories
hemoflow init
The four directories correspond with the following image series:
- FH - Feet to head flow images.
- AP - Anterior to posterior flow images.
- RL - Right to left flow images.
Copy your dicom
image series to files/
directory.
files/
ββββFH
β ββββIM1.DCM
β ββββIM2.DCM
β ββββ...
β ββββIMX.DCM
ββββAP
β ββββIM1.DCM
β ββββIM2.DCM
β ββββ...
β ββββIMX.DCM
ββββRL
ββββIM1.DCM
ββββIM2.DCM
ββββ...
ββββIMX.DCM
Finally, build volumetric the velocity field from dicom files.
hemoflow build
Data files in .csv
format will be created for each timestep in output/
folder.
output/
ββββdata.csv.0
ββββdata.csv.26
ββββ...
ββββdata.csv.603
Each dataframe will have cordinates and velocity components for each axis.
Important
Velocity components are meant to be in cm/s.
This project is licensed under the MIT License. See license.txt
file for details.