Skip to content

Commit efc0518

Browse files
committed
👔 No nuisance if no regressors
1 parent 763af4e commit efc0518

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

CPAC/nuisance/nuisance.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2419,6 +2419,8 @@ def nuisance_regressors_generation(
24192419
space: Literal["T1w", "bold"],
24202420
) -> tuple[Workflow, dict]:
24212421
"""Generate nuisance regressors."""
2422+
if not opt:
2423+
return wf, {}
24222424
prefixes = [f"space-{space}_"] * 2
24232425
reg_tool = None
24242426
if space == "T1w":
@@ -2659,6 +2661,8 @@ def nuisance_regression(wf, cfg, strat_pool: StratPool, pipe_num, opt, space, re
26592661
26602662
outputs : dict
26612663
"""
2664+
if not opt:
2665+
return wf, {}
26622666
opt = strat_pool.regressor_dct
26632667
bandpass = "Bandpass" in opt
26642668
bandpass_before = (

0 commit comments

Comments
 (0)