Skip to content

Commit

Permalink
Mask image in run level's noise removal
Browse files Browse the repository at this point in the history
  • Loading branch information
bclenet committed Jun 26, 2024
1 parent 11fd1a6 commit cf8934d
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion narps_open/pipelines/team_B23O.py
Original file line number Diff line number Diff line change
Expand Up @@ -140,6 +140,8 @@ def get_run_level_analysis(self):
templates = {
'func' : join('derivatives', 'fmriprep', 'sub-{subject_id}', 'func',
'sub-{subject_id}_task-MGT_run-{run_id}_bold_space-MNI152NLin2009cAsym_preproc.nii.gz'),
'mask' : join('derivatives', 'fmriprep', 'sub-{subject_id}', 'func',
'sub-{subject_id}_task-MGT_run-{run_id}_bold_space-MNI152NLin2009cAsym_brainmask.nii.gz'),
'events' : join('sub-{subject_id}', 'func',
'sub-{subject_id}_task-MGT_run-{run_id}_events.tsv'),
'confounds' : join('derivatives', 'fmriprep', 'sub-{subject_id}', 'func',
Expand Down Expand Up @@ -173,6 +175,7 @@ def get_run_level_analysis(self):
noise_removal.inputs.filter_all = True
run_level.connect(select_files, 'func', noise_removal, 'in_file')
run_level.connect(confounds, 'confounds_file', noise_removal, 'design_file')
run_level.connect(select_files, 'mask', noise_removal, 'mask')

# SpecifyModel Node - Generate run level model
specify_model = Node(SpecifyModel(), name = 'specify_model')
Expand All @@ -196,7 +199,7 @@ def get_run_level_analysis(self):
run_level.connect(model_design, 'fsf_files', model_generation, 'fsf_file')

# FILMGLS Node - Estimate first level model
model_estimate = Node(FILMGLS(), name='model_estimate')
model_estimate = Node(FILMGLS(), name = 'model_estimate')
model_estimate.inputs.output_pwdata = True
model_estimate.inputs.smooth_autocorr = True
run_level.connect(select_files, 'func', model_estimate, 'in_file')
Expand Down

0 comments on commit cf8934d

Please sign in to comment.