Skip to content
This repository was archived by the owner on Mar 18, 2026. It is now read-only.

Latest commit

 

History

History
23 lines (16 loc) · 1.1 KB

File metadata and controls

23 lines (16 loc) · 1.1 KB

4Dflow Python Codes

Python scripts for preprocessing, analysis, and visualization of 4D flow inlet velocity profiles, with a focus on patient-specific and statistical shape model workflows.

Overview

This repository contains standalone scripts used to:

  • preprocess probed 4D flow velocity data,
  • align and shift temporal flow profiles,
  • build statistical shape model inputs,
  • run PCA-based analyses,
  • visualize flow-related quantities and extracted volumes.

Most scripts are configured as research workflows rather than packaged command-line tools. They currently use hard-coded local paths and expect project-specific input data on disk.

Main steps

  1. dicom_to_vtk .py: after obtaining .vtk files, open it in Paraview, then exported as .e file————open .e file in Ensight, and crop a plane at the inlet

  2. plane_selection_meshinlet.py: the plane cropped from step 1 will be used to generate .vtp files

  3. Preprocessing.py: this code is to calculate the mean velocity profile for all subjects.

  4. mainSSM.py

  5. syntheticDatasetGeneration.py: set the size of synthetic data, and acceptance criteria