Skip to content

Commit 91265b0

Browse files
mgxdeffigies
andauthored
Apply suggestions from code review
Co-authored-by: Chris Markiewicz <[email protected]>
1 parent 6c448a2 commit 91265b0

File tree

3 files changed

+5
-8
lines changed

3 files changed

+5
-8
lines changed

fmriprep/cli/parser.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -349,9 +349,9 @@ def _slice_time_ref(value, parser):
349349
"--bold2anat-init",
350350
choices=["auto", "t1w", "header"],
351351
default="auto",
352-
help="Method of BOLD to anatomical coregistration. If `auto`, a T2w image is used if "
352+
help="Method of initial BOLD to anatomical coregistration. If `auto`, a T2w image is used if "
353353
"available, otherwise the T1w image. `t1w` forces use of the T1w, and `header` uses "
354-
"the T1w header information.",
354+
"the BOLD header information without an initial registration.",
355355
)
356356
g_conf.add_argument(
357357
"--bold2anat-dof",

fmriprep/workflows/base.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -624,7 +624,7 @@ def init_single_subject_wf(subject_id: str):
624624
)
625625

626626
# Before initializing BOLD workflow, select/verify anatomical target for coregistration
627-
if config.workflow.bold2anat_init in ('auto', 't2w'):
627+
if config.workflow.bold2anat_init == 'auto':
628628
config.workflow.bold2anat_init = 't2w' if subject_data['t2w'] else 't1w'
629629

630630
for bold_series in bold_runs:

fmriprep/workflows/bold/registration.py

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -289,7 +289,7 @@ def init_bbreg_wf(
289289
use_t2w = bold2anat_init == 't2w'
290290
if use_t2w:
291291
workflow.__desc__ += (
292-
" A T2w reference was used as an intermediate volume to improve tissue contrast."
292+
" The aligned T2w image was used for initial co-registration."
293293
)
294294

295295
inputnode = pe.Node(
@@ -312,7 +312,7 @@ def init_bbreg_wf(
312312
)
313313

314314
if bold2anat_init not in ty.get_args(RegistrationInit):
315-
raise ValueError(f"Unknown BOLD-anat initialization option: {bold2anat_init}")
315+
raise ValueError(f"Unknown BOLD-to-anatomical initialization option: {bold2anat_init}")
316316

317317
# For now make BBR unconditional - in the future, we can fall back to identity,
318318
# but adding the flexibility without testing seems a bit dangerous
@@ -396,9 +396,6 @@ def init_bbreg_wf(
396396
(bbregister, transforms, [('out_lta_file', 'in1')]),
397397
]) # fmt:skip
398398

399-
if use_t2w:
400-
workflow.connect(fssource, 'T2', bbregister, 'intermediate_file')
401-
402399
# Short-circuit workflow building, use boundary-based registration
403400
if use_bbr is True:
404401
outputnode.inputs.fallback = False

0 commit comments

Comments
 (0)