From cbd08ecac8c65d299e28a6299fbac7a4b1c8a1ea Mon Sep 17 00:00:00 2001 From: Taylor Salo Date: Fri, 26 Jul 2024 15:03:22 -0400 Subject: [PATCH 1/3] Add space-fsaverage to sphere_reg files. --- .circleci/ds005_outputs.txt | 4 ++-- smriprep/workflows/outputs.py | 2 ++ 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/.circleci/ds005_outputs.txt b/.circleci/ds005_outputs.txt index 779c44abc6..e69a233817 100644 --- a/.circleci/ds005_outputs.txt +++ b/.circleci/ds005_outputs.txt @@ -22,10 +22,10 @@ smriprep/sub-01/anat/sub-01_dseg.nii.gz smriprep/sub-01/anat/sub-01_from-fsnative_to-T1w_mode-image_xfm.txt smriprep/sub-01/anat/sub-01_from-T1w_to-fsnative_mode-image_xfm.txt smriprep/sub-01/anat/sub-01_hemi-L_curv.shape.gii -smriprep/sub-01/anat/sub-01_hemi-L_desc-reg_sphere.surf.gii smriprep/sub-01/anat/sub-01_hemi-L_inflated.surf.gii smriprep/sub-01/anat/sub-01_hemi-L_midthickness.surf.gii smriprep/sub-01/anat/sub-01_hemi-L_pial.surf.gii +smriprep/sub-01/anat/sub-01_hemi-L_space-fsaverage_desc-reg_sphere.surf.gii smriprep/sub-01/anat/sub-01_hemi-L_space-fsLR_desc-msmsulc_sphere.surf.gii smriprep/sub-01/anat/sub-01_hemi-L_space-fsLR_desc-reg_sphere.surf.gii smriprep/sub-01/anat/sub-01_hemi-L_sphere.surf.gii @@ -33,10 +33,10 @@ smriprep/sub-01/anat/sub-01_hemi-L_sulc.shape.gii smriprep/sub-01/anat/sub-01_hemi-L_thickness.shape.gii smriprep/sub-01/anat/sub-01_hemi-L_white.surf.gii smriprep/sub-01/anat/sub-01_hemi-R_curv.shape.gii -smriprep/sub-01/anat/sub-01_hemi-R_desc-reg_sphere.surf.gii smriprep/sub-01/anat/sub-01_hemi-R_inflated.surf.gii smriprep/sub-01/anat/sub-01_hemi-R_midthickness.surf.gii smriprep/sub-01/anat/sub-01_hemi-R_pial.surf.gii +smriprep/sub-01/anat/sub-01_hemi-R_space-fsaverage_desc-reg_sphere.surf.gii smriprep/sub-01/anat/sub-01_hemi-R_space-fsLR_desc-msmsulc_sphere.surf.gii smriprep/sub-01/anat/sub-01_hemi-R_space-fsLR_desc-reg_sphere.surf.gii smriprep/sub-01/anat/sub-01_hemi-R_sphere.surf.gii diff --git a/smriprep/workflows/outputs.py b/smriprep/workflows/outputs.py index dee84d17a0..af0159ff22 100644 --- a/smriprep/workflows/outputs.py +++ b/smriprep/workflows/outputs.py @@ -731,6 +731,8 @@ def init_ds_surfaces_wf( ds_surf.inputs.desc = 'reg' if surf == 'sphere_reg_fsLR': ds_surf.inputs.space = 'fsLR' + elif surf == 'sphere_reg': + ds_surf.inputs.space = 'fsaverage' # fmt:off workflow.connect([ From fab7966c6a2cf82424f653bbf68a1d14423d4e21 Mon Sep 17 00:00:00 2001 From: Taylor Salo Date: Fri, 26 Jul 2024 16:05:54 -0400 Subject: [PATCH 2/3] Streamline if/else. --- smriprep/workflows/outputs.py | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/smriprep/workflows/outputs.py b/smriprep/workflows/outputs.py index af0159ff22..4a8764a6dd 100644 --- a/smriprep/workflows/outputs.py +++ b/smriprep/workflows/outputs.py @@ -724,15 +724,11 @@ def init_ds_surfaces_wf( run_without_submitting=True, ) if surf.startswith('sphere_reg'): - if surf == 'sphere_reg_msm': - ds_surf.inputs.desc = 'msmsulc' + ds_surf.inputs.space, ds_surf.inputs.desc = 'fsaverage', 'reg' # Default + if surf == 'sphere_reg_fsLR': ds_surf.inputs.space = 'fsLR' - else: - ds_surf.inputs.desc = 'reg' - if surf == 'sphere_reg_fsLR': - ds_surf.inputs.space = 'fsLR' - elif surf == 'sphere_reg': - ds_surf.inputs.space = 'fsaverage' + elif surf == 'sphere_reg_msm': + ds_surf.inputs.space, ds_surf.inputs.desc = 'fsLR', 'msmsulc' # fmt:off workflow.connect([ From 0d6d953d042273fdf4107362b5aecba18d3cfdde Mon Sep 17 00:00:00 2001 From: Taylor Salo Date: Fri, 26 Jul 2024 16:06:20 -0400 Subject: [PATCH 3/3] Reorder expected outputs. --- .circleci/ds005_outputs.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.circleci/ds005_outputs.txt b/.circleci/ds005_outputs.txt index e69a233817..285c44e906 100644 --- a/.circleci/ds005_outputs.txt +++ b/.circleci/ds005_outputs.txt @@ -25,9 +25,9 @@ smriprep/sub-01/anat/sub-01_hemi-L_curv.shape.gii smriprep/sub-01/anat/sub-01_hemi-L_inflated.surf.gii smriprep/sub-01/anat/sub-01_hemi-L_midthickness.surf.gii smriprep/sub-01/anat/sub-01_hemi-L_pial.surf.gii -smriprep/sub-01/anat/sub-01_hemi-L_space-fsaverage_desc-reg_sphere.surf.gii smriprep/sub-01/anat/sub-01_hemi-L_space-fsLR_desc-msmsulc_sphere.surf.gii smriprep/sub-01/anat/sub-01_hemi-L_space-fsLR_desc-reg_sphere.surf.gii +smriprep/sub-01/anat/sub-01_hemi-L_space-fsaverage_desc-reg_sphere.surf.gii smriprep/sub-01/anat/sub-01_hemi-L_sphere.surf.gii smriprep/sub-01/anat/sub-01_hemi-L_sulc.shape.gii smriprep/sub-01/anat/sub-01_hemi-L_thickness.shape.gii @@ -36,9 +36,9 @@ smriprep/sub-01/anat/sub-01_hemi-R_curv.shape.gii smriprep/sub-01/anat/sub-01_hemi-R_inflated.surf.gii smriprep/sub-01/anat/sub-01_hemi-R_midthickness.surf.gii smriprep/sub-01/anat/sub-01_hemi-R_pial.surf.gii -smriprep/sub-01/anat/sub-01_hemi-R_space-fsaverage_desc-reg_sphere.surf.gii smriprep/sub-01/anat/sub-01_hemi-R_space-fsLR_desc-msmsulc_sphere.surf.gii smriprep/sub-01/anat/sub-01_hemi-R_space-fsLR_desc-reg_sphere.surf.gii +smriprep/sub-01/anat/sub-01_hemi-R_space-fsaverage_desc-reg_sphere.surf.gii smriprep/sub-01/anat/sub-01_hemi-R_sphere.surf.gii smriprep/sub-01/anat/sub-01_hemi-R_sulc.shape.gii smriprep/sub-01/anat/sub-01_hemi-R_thickness.shape.gii