Skip to content

Commit c961b3c

Browse files
authored
ENH: Write out cortex mask GIFTIs (#3491)
Closes #3433. ## Changes proposed in this pull request - Collect cortex mask GIFTIs from `anat_fit_wf` instead of `hcp_morphometrics_wf`.
2 parents c439ea6 + 0d9c10e commit c961b3c

File tree

7 files changed

+21
-6
lines changed

7 files changed

+21
-6
lines changed

.circleci/ds005_fasttrack_outputs.txt

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,11 +12,15 @@ sub-01
1212
sub-01/anat
1313
sub-01/anat/sub-01_desc-ribbon_mask.json
1414
sub-01/anat/sub-01_desc-ribbon_mask.nii.gz
15+
sub-01/anat/sub-01_hemi-L_desc-cortex_mask.json
16+
sub-01/anat/sub-01_hemi-L_desc-cortex_mask.label.gii
1517
sub-01/anat/sub-01_hemi-L_desc-preproc_sphere.surf.gii
1618
sub-01/anat/sub-01_hemi-L_desc-preproc_white.surf.gii
1719
sub-01/anat/sub-01_hemi-L_space-fsLR_desc-msmsulc_sphere.surf.gii
1820
sub-01/anat/sub-01_hemi-L_space-fsLR_desc-reg_sphere.surf.gii
1921
sub-01/anat/sub-01_hemi-L_space-fsaverage_desc-reg_sphere.surf.gii
22+
sub-01/anat/sub-01_hemi-R_desc-cortex_mask.json
23+
sub-01/anat/sub-01_hemi-R_desc-cortex_mask.label.gii
2024
sub-01/anat/sub-01_hemi-R_desc-preproc_sphere.surf.gii
2125
sub-01/anat/sub-01_hemi-R_desc-preproc_white.surf.gii
2226
sub-01/anat/sub-01_hemi-R_space-fsLR_desc-msmsulc_sphere.surf.gii

.circleci/ds005_outputs.txt

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,8 @@ sub-01/anat/sub-01_from-fsnative_to-T1w_mode-image_xfm.txt
2121
sub-01/anat/sub-01_from-MNI152NLin2009cAsym_to-T1w_mode-image_xfm.h5
2222
sub-01/anat/sub-01_from-T1w_to-fsnative_mode-image_xfm.txt
2323
sub-01/anat/sub-01_from-T1w_to-MNI152NLin2009cAsym_mode-image_xfm.h5
24+
sub-01/anat/sub-01_hemi-L_desc-cortex_mask.json
25+
sub-01/anat/sub-01_hemi-L_desc-cortex_mask.label.gii
2426
sub-01/anat/sub-01_hemi-L_midthickness.surf.gii
2527
sub-01/anat/sub-01_hemi-L_pial.surf.gii
2628
sub-01/anat/sub-01_hemi-L_space-fsLR_desc-msmsulc_sphere.surf.gii
@@ -30,6 +32,8 @@ sub-01/anat/sub-01_hemi-L_sphere.surf.gii
3032
sub-01/anat/sub-01_hemi-L_sulc.shape.gii
3133
sub-01/anat/sub-01_hemi-L_thickness.shape.gii
3234
sub-01/anat/sub-01_hemi-L_white.surf.gii
35+
sub-01/anat/sub-01_hemi-R_desc-cortex_mask.json
36+
sub-01/anat/sub-01_hemi-R_desc-cortex_mask.label.gii
3337
sub-01/anat/sub-01_hemi-R_midthickness.surf.gii
3438
sub-01/anat/sub-01_hemi-R_pial.surf.gii
3539
sub-01/anat/sub-01_hemi-R_space-fsLR_desc-msmsulc_sphere.surf.gii

.circleci/ds005_partial_fasttrack_outputs.txt

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,8 @@ sub-01
1212
sub-01/anat
1313
sub-01/anat/sub-01_desc-ribbon_mask.json
1414
sub-01/anat/sub-01_desc-ribbon_mask.nii.gz
15+
sub-01/anat/sub-01_hemi-L_desc-cortex_mask.json
16+
sub-01/anat/sub-01_hemi-L_desc-cortex_mask.label.gii
1517
sub-01/anat/sub-01_hemi-L_desc-preproc_sphere.surf.gii
1618
sub-01/anat/sub-01_hemi-L_desc-preproc_white.surf.gii
1719
sub-01/anat/sub-01_hemi-L_space-fsLR_den-32k_desc-preproc_midthickness.surf.gii
@@ -20,6 +22,8 @@ sub-01/anat/sub-01_hemi-L_space-fsLR_den-32k_desc-preproc_white.surf.gii
2022
sub-01/anat/sub-01_hemi-L_space-fsLR_desc-msmsulc_sphere.surf.gii
2123
sub-01/anat/sub-01_hemi-L_space-fsLR_desc-reg_sphere.surf.gii
2224
sub-01/anat/sub-01_hemi-L_space-fsaverage_desc-reg_sphere.surf.gii
25+
sub-01/anat/sub-01_hemi-R_desc-cortex_mask.json
26+
sub-01/anat/sub-01_hemi-R_desc-cortex_mask.label.gii
2327
sub-01/anat/sub-01_hemi-R_desc-preproc_sphere.surf.gii
2428
sub-01/anat/sub-01_hemi-R_desc-preproc_white.surf.gii
2529
sub-01/anat/sub-01_hemi-R_space-fsLR_den-32k_desc-preproc_midthickness.surf.gii

.circleci/ds005_partial_outputs.txt

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,8 @@ sub-01/anat/sub-01_from-MNI152NLin6Asym_to-T1w_mode-image_xfm.h5
2323
sub-01/anat/sub-01_from-T1w_to-fsnative_mode-image_xfm.txt
2424
sub-01/anat/sub-01_from-T1w_to-MNI152NLin2009cAsym_mode-image_xfm.h5
2525
sub-01/anat/sub-01_from-T1w_to-MNI152NLin6Asym_mode-image_xfm.h5
26+
sub-01/anat/sub-01_hemi-L_desc-cortex_mask.json
27+
sub-01/anat/sub-01_hemi-L_desc-cortex_mask.label.gii
2628
sub-01/anat/sub-01_hemi-L_midthickness.surf.gii
2729
sub-01/anat/sub-01_hemi-L_pial.surf.gii
2830
sub-01/anat/sub-01_hemi-L_space-fsLR_den-32k_midthickness.surf.gii
@@ -35,6 +37,8 @@ sub-01/anat/sub-01_hemi-L_sphere.surf.gii
3537
sub-01/anat/sub-01_hemi-L_sulc.shape.gii
3638
sub-01/anat/sub-01_hemi-L_thickness.shape.gii
3739
sub-01/anat/sub-01_hemi-L_white.surf.gii
40+
sub-01/anat/sub-01_hemi-L_desc-cortex_mask.json
41+
sub-01/anat/sub-01_hemi-L_desc-cortex_mask.label.gii
3842
sub-01/anat/sub-01_hemi-R_midthickness.surf.gii
3943
sub-01/anat/sub-01_hemi-R_pial.surf.gii
4044
sub-01/anat/sub-01_hemi-R_space-fsLR_den-32k_midthickness.surf.gii

docs/outputs.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -137,6 +137,7 @@ If FreeSurfer reconstructions are used, the following surface files are generate
137137
sub-<subject_label>_hemi-[LR]_desc-reg_sphere.surf.gii
138138
sub-<subject_label>_hemi-[LR]_space-fsLR_desc-reg_sphere.surf.gii
139139
sub-<subject_label>_hemi-[LR]_space-fsLR_desc-msmsulc_sphere.surf.gii
140+
sub-<subject_label>_hemi-[LR]_desc-cortex_mask.label.gii
140141

141142
The registration spheres target ``fsaverage`` and ``fsLR`` spaces. If MSM
142143
is enabled (i.e., the ``--no-msm`` flag is not passed), then the ``msmsulc``

fmriprep/workflows/base.py

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -503,12 +503,12 @@ def init_single_subject_wf(subject_id: str):
503503
f'outputnode.sphere_reg_{"msm" if msm_sulc else "fsLR"}',
504504
'inputnode.sphere_reg_fsLR',
505505
),
506+
('outputnode.cortex_mask', 'inputnode.roi'),
506507
]),
507508
(hcp_morphometrics_wf, morph_grayords_wf, [
508509
('outputnode.curv', 'inputnode.curv'),
509510
('outputnode.thickness', 'inputnode.thickness'),
510511
('outputnode.sulc', 'inputnode.sulc'),
511-
('outputnode.roi', 'inputnode.roi'),
512512
]),
513513
(resample_surfaces_wf, morph_grayords_wf, [
514514
('outputnode.midthickness_fsLR', 'inputnode.midthickness_fsLR'),
@@ -842,9 +842,7 @@ def init_single_subject_wf(subject_id: str):
842842
workflow.connect([
843843
(select_MNI6_xfm, bold_wf, [('anat2std_xfm', 'inputnode.anat2mni6_xfm')]),
844844
(select_MNI6_tpl, bold_wf, [('brain_mask', 'inputnode.mni6_mask')]),
845-
(hcp_morphometrics_wf, bold_wf, [
846-
('outputnode.roi', 'inputnode.cortex_mask'),
847-
]),
845+
(anat_fit_wf, bold_wf, [('outputnode.cortex_mask', 'inputnode.cortex_mask')]),
848846
(resample_surfaces_wf, bold_wf, [
849847
('outputnode.midthickness_fsLR', 'inputnode.midthickness_fsLR'),
850848
]),

pyproject.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,15 +27,15 @@ dependencies = [
2727
"nireports >= 24.1.0",
2828
"nitime >= 0.9",
2929
"nitransforms >= 24.1.1",
30-
"niworkflows >= 1.12.2",
30+
"niworkflows @ git+https://github.com/nipreps/niworkflows.git@master",
3131
"numpy >= 1.24",
3232
"packaging >= 24",
3333
"pandas >= 1.2",
3434
"psutil >= 5.4",
3535
"pybids >= 0.16",
3636
"requests >= 2.27",
3737
"sdcflows >= 2.13.1",
38-
"smriprep >= 0.18.0",
38+
"smriprep @ git+https://github.com/nipreps/smriprep.git@master",
3939
"tedana >= 25.0.0",
4040
"templateflow >= 24.2.2",
4141
"transforms3d >= 0.4",

0 commit comments

Comments
 (0)