Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RF: Move to fit/apply workflow #360

Draft
wants to merge 120 commits into
base: master
Choose a base branch
from
Draft

RF: Move to fit/apply workflow #360

wants to merge 120 commits into from

Conversation

mgxd
Copy link
Collaborator

@mgxd mgxd commented Apr 29, 2024

The goal of this PR is mirror workflow changes in fMRIPrep, splitting the processing into "fit" and "apply" modes.

This is still a work-in-progress.

New features:

  • --level {minimal, resampling, full} to specify levels of outputs:

    • minimal produces anatomical template, mask, anatomical -> template registrations, surface reconstruction. These can then be further processed and/or manually edited and reused as --derivatives inputs.
    • full produces all outputs, like previous versions of nibabies
  • Increased control in the use of previously computed derivatives

    • Derivatives no longer need to be in native T1w/T2w space, as long as a T1w/T2w preprocessed template is include.
  • Selective anatomical reference preference with --reference-anatomical flag

    • Previously, T1w was preferred as the output space.
    • If no option is specified, will select based on
        1. surface reconstruction method
        1. participant age

Example MCRIBS derivatives input and command

Generating surfaces with MCRIBS still requires precomputed segmentations - this is an example directory layout that can be used:

data/derivatives/anat
├── dataset_description.json
└── sub-01
    └── ses-1mo
        └── anat
            ├── sub-01_ses-1mo_desc-preproc_T1w.nii.gz
            ├── sub-01_ses-1mo_desc-preproc_T2w.nii.gz
            ├── sub-01_ses-1mo_space-T2w_desc-aseg_dseg.nii.gz
            └── sub-01_ses-1mo_space-T2w_desc-brain_mask.nii.gz
  • Note that sub-01_ses-1mo_desc-preproc_T2w.nii.gz is a denoised and INU corrected image, and is used as space-T2w. The aseg and mask are in that image space.
nibabies /data /data/derivatives/nibabies participant \
-w /work --participant-label 01 \
--fs-subjects-dir /opt/freesurfer/subjects \
--derivatives anat=/data/derivatives/anat \
--anat-only --surface-recon-method mcribs --cifti-output -s 1mo

Closes #87, #218, #288, #294, #307

mgxd added 30 commits March 28, 2024 15:53
@mgxd mgxd force-pushed the rf/fit-apply branch 2 times, most recently from 144195c to 756d259 Compare June 3, 2024 03:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add T2w anatomical images to the report
1 participant