-
Notifications
You must be signed in to change notification settings - Fork 296
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[RTM] RF: Separate BOLD reference generation from head-motion correction #655
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just left a comment about documentation, but it is up to you the ordering of documenting workflows. This PR will make FMRIPREP easier to maintain, great work!
"""Generate a reference BOLD image for a series | ||
|
||
This image is the target of head-motion-correction, and the subject of distortion | ||
correction and registration to T1w and template spaces. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Are you planning on adding the workflow generation code within #638 or should we already require ourselves to write the graph whenever we add a new workflow? (even for small ones like this).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The plan was to get the docstring right in whichever PR comes second, since there are going to be conflicts either way.
name='outputnode') | ||
|
||
# Simplify manually setting input image | ||
if bold_file is not None: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
'ref_image_brain', 'movpar_file', 'n_volumes_to_discard', | ||
'bold_mask_report']), name='outputnode') | ||
outputnode = pe.Node( | ||
niu.IdentityInterface(fields=['xforms', 'bold_hmc', 'bold_split', 'movpar_file']), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is a lot better now!
As discussed in #253, constructing a mean BOLD image would require a reference from each run to be created and merged. This PR takes a first step toward that end by separating reference generation from HMC.
It is set up so that a list of workflows could be easily generated from a list of BOLD images, but at the moment, it's simply moved to the start of
init_func_preproc_wf
.