DDSurfer
DDSurfer: A Weakly-Supervised Dual-Stream Deep Learning Framework for Cortical Surface Reconstruction from Diffusion MRI
Install / Use
/learn @ChengjinLii/DDSurferREADME
DDSurfer Release
DDSurfer reconstructs white and pial cortical surfaces from diffusion MRI inputs. This release bundles preprocessing utilities, dual-stream TANet inference, and post-processing tools in a single repository.
Typical Workflow
-
Prepare data
Place each subject underDTI-inputs/<subID>with the diffusion-derived volumes required byData-Preprocessing.sh(FA, eigenvalues, trace, MD, brain mask, transform). -
Run preprocessing
bash Data-Preprocessing.sh --subject <subID>Use
--input-root/--output-rootif your directories differ from the defaults. -
Predict cortical surfaces (MNI space outputs)
python3 ddsurfer_predict_lh_dualstream.py --subjects <subID> python3 ddsurfer_predict_rh_dualstream.py --subjects <subID>Adjust
--device,--data_type, and--input_root/--output_diras needed. The scripts require the outputs from preprocessing and write meshes topred_results_DDSurfer/mni/<subID>/. -
Transform meshes back to native space
bash utils/space_MNI2orig.sh --subject <subID> --mode wholeThe resulting surfaces are written to
pred_results_DDSurfer/native/<subID>/. -
One-command pipeline (Python)
python3 run_ddsurfer_pipeline.py --subject <subID> -
One-command pipeline (Shell)
bash run_ddsurfer_pipeline.sh --subject <subID>
Both wrappers accept flags to skip preprocessing or post-processing and expose the same configuration knobs (input/output roots, device, prediction mode).
Key Dependencies
- Python 3.8+
- PyTorch with CUDA support (optional for GPU acceleration)
- SimpleITK, nibabel, trimesh, tqdm, pytorch3d (for loss utilities)
Refer to project-specific requirements for exact versions used during training.
Support
Open issues or questions can be directed through the repository’s issue tracker.
Acknowledgments
This work is in part supported by the National Key R&D Program of China (No. 2023YFE0118600), the National Natural Science Foundation of China (No. 62371107).
