xcp_d.workflows.bold.nifti module

Workflows for post-processing NIfTI-format BOLD data.

xcp_d.workflows.bold.nifti.init_postprocess_nifti_wf(bold_file, head_radius, run_data, t1w_available, t2w_available, n_runs, has_multiple_runs, mem_gb, name='bold_postprocess_wf')[source]

Organize the bold processing workflow.

Workflow Graph
../_images/xcp_d-workflows-bold-nifti-1.png

(Source code, png, svg, pdf)

Parameters:
  • bold_file (str) – bold file for post processing

  • run_data (dict)

  • t1w_available

  • t2w_available

  • n_runs – Number of runs being postprocessed by XCP-D. This is just used for the boilerplate, as this workflow only posprocesses one run.

  • has_multiple_runs – Whether there are multiple runs for this task or not. Interacts with the output_run_wise_correlations parameter.

  • mem_gb (dict) – Dictionary of memory allocations with keys 'bold' and 'volume'.

  • name (str, optional) – Name of the workflow. This is used for working directories and workflow graphs. Default is “nifti_postprocess_wf”.

Inputs:
  • bold_file – BOLD series NIfTI file

  • boldref (str) – Path to the BOLD reference file associated with the target BOLD run. This comes from the preprocessing derivatives. Loaded in this workflow.

  • bold_mask – bold_mask from fmriprep Loaded in this workflow.

  • template_to_anat_xfm (str) – Path to the MNI-to-T1w transform file. May be “identity”, for testing purposes. Fed from the subject workflow.

  • t1w – Preprocessed T1w image, warped to standard space. Fed from the subject workflow.

  • t2w – Preprocessed T2w image, warped to standard space. Fed from the subject workflow.

  • anat_brainmask – T1w brain mask in standard space, used for transforms in the QC report workflow. Fed from the subject workflow.

  • motion_file

  • motion_json

  • dummy_scans (int or “auto”) – Number of volumes to remove from the beginning of each run. If set to ‘auto’, xcp_d will extract non-steady-state volume indices from the preprocessing derivatives’ confounds file.

Outputs:
  • name_source (str) – Path to the file that will be used as the source_file for derivatives. This is generally the preprocessed BOLD file. This file does not need to exist (e.g., in the case of a concatenated version of the filename).

  • preprocessed_bold (str) – The preprocessed BOLD file, after dummy scan removal.

  • temporal_mask (str) – Temporal mask; all values above fd_thresh set to 1. This is a TSV file with one column: ‘framewise_displacement’.

  • motion_file – After dummy scan removal.

  • denoised_interpolated_bold (str) – Path to the censored, denoised, interpolated, and filtered BOLD file. This file is the result of denoising the censored preprocessed BOLD data, followed by cubic spline interpolation and band-pass filtering.

    This output should not be used for analysis. It is primarily for DCAN QC plots.

  • boldref (str) – Path to the BOLD reference file associated with the target BOLD run. This comes from the preprocessing derivatives.

  • bold_mask

  • timeseries (list of str) – List of paths to atlas-specific time series TSV files. These time series are produced from the censored_denoised_bold outputs.

  • timeseries_ciftis (list of str) – List of paths to atlas-specific time series CIFTI (ptseries) files. These time series are produced from the censored_denoised_bold outputs. This will not be defined.

References