From 71aa02723aa1bbcb032d8d69422e026edd1bdc87 Mon Sep 17 00:00:00 2001 From: Chris Markiewicz Date: Fri, 29 Sep 2023 11:05:37 -0400 Subject: [PATCH] FIX: Drop unused std_xfms and get_outputnode_spec() --- smriprep/data/io_spec.json | 18 ------------------ smriprep/utils/bids.py | 25 ------------------------- 2 files changed, 43 deletions(-) diff --git a/smriprep/data/io_spec.json b/smriprep/data/io_spec.json index 21dcc1f405..7a6382b882 100644 --- a/smriprep/data/io_spec.json +++ b/smriprep/data/io_spec.json @@ -70,24 +70,6 @@ "mode": "image" } }, - "std_xfms": { - "anat2std_xfm": { - "datatype": "anat", - "extension": "h5", - "from": "T1w", - "to": [], - "suffix": "xfm", - "mode": "image" - }, - "std2anat_xfm": { - "datatype": "anat", - "extension": "h5", - "from": [], - "to": "T1w", - "suffix": "xfm", - "mode": "image" - } - }, "surfaces": { "white": { "datatype": "anat", diff --git a/smriprep/utils/bids.py b/smriprep/utils/bids.py index c389c00511..04aa3e8814 100644 --- a/smriprep/utils/bids.py +++ b/smriprep/utils/bids.py @@ -28,31 +28,6 @@ from bids.layout import BIDSLayout -def get_outputnode_spec(): - """ - Generate outputnode's fields from I/O spec file. - - Examples - -------- - >>> get_outputnode_spec() # doctest: +NORMALIZE_WHITESPACE - ['t1w_preproc', 't1w_mask', 't1w_dseg', 't1w_tpms', - 'std_preproc', 'std_mask', 'std_dseg', 'std_tpms', - 'anat2std_xfm', 'std2anat_xfm', - 't1w2fsnative_xfm', 'fsnative2t1w_xfm', - 'white', 'pial', 'midthickness', 'sphere', - 'thickness', 'sulc', 'curv', - 'sphere_reg', 'sphere_reg_fsLR', 'sphere_reg_msm', - 'anat_ribbon'] - - """ - spec = loads(Path(pkgrf("smriprep", "data/io_spec.json")).read_text())["queries"] - fields = ["_".join((m, s)) for m in ("t1w", "std") for s in spec["baseline"].keys()] - fields += [s for s in spec["std_xfms"].keys()] - fields += [s for s in spec["surfaces"].keys()] - fields += [s for s in spec["masks"].keys()] - return fields - - def collect_derivatives(derivatives_dir, subject_id, std_spaces, spec=None, patterns=None): """Gather existing derivatives and compose a cache.""" if spec is None or patterns is None: