aslprep.interfaces.confounds module

Interfaces for calculating and collecting confounds.

class ComputeCBFQC(from_file=None, resource_monitor=None, **inputs)[source]

Bases: SimpleInterface

Calculate a series of CBF quality control metrics for GE data.

compute qc from confound regressors and cbf maps, coregistration and regsitration indexes

Mandatory Inputs:
  • asl_mask (a pathlike object or string representing an existing file) – ASL mask in native ASL reference space.

  • csf_tpm (a pathlike object or string representing an existing file) – CSF tissue probability map.

  • gm_tpm (a pathlike object or string representing an existing file) – Gray matter tissue probability map.

  • mean_cbf (a pathlike object or string representing an existing file) – Mean CBF from standard CBF calculation.

  • name_source (a pathlike object or string representing an existing file) – Original asl_file. Used to extract entity information.

  • t1w_mask (a pathlike object or string representing an existing file) – T1w mask in native space.

  • wm_tpm (a pathlike object or string representing an existing file) – White matter tissue probability map.

Optional Inputs:
  • asl_mask_std (a pathlike object or string representing an existing file) – ASL mask in standard space.

  • confounds_file (a pathlike object or string representing an existing file) – Confounds file. Will not be defined for GE data.

  • mean_cbf_basil (a pathlike object or string representing an existing file) – Mean CBF produced by BASIL.

  • mean_cbf_gm_basil (a pathlike object or string representing an existing file) – GM partial volume corrected CBF with BASIL.

  • mean_cbf_score (a pathlike object or string representing an existing file) – Mean CBF after SCORE censoring.

  • mean_cbf_scrub (a pathlike object or string representing an existing file) – Mean CBF after SCRUB denoising.

  • rmsd_file (a pathlike object or string representing an existing file) – RMSD file. Will not be defined for GE data.

  • template_mask (a pathlike object or string representing an existing file) – Template mask or image.

  • tpm_threshold (a float) – Tissue probability threshold for binarizing GM, WM, and CSF masks. (Nipype default value: 0.7)

Outputs:
  • qc_file (a pathlike object or string representing an existing file) – Qc file.

  • qc_metadata (a pathlike object or string representing an existing file) – Qc metadata.

class GatherCBFConfounds(from_file=None, resource_monitor=None, **inputs)[source]

Bases: SimpleInterface

Combine various sources of confounds in one TSV file.

Optional Inputs:
  • score (a pathlike object or string representing an existing file) – SCORE outlier index.

  • signals (a pathlike object or string representing an existing file) – Input signals.

Outputs:
  • confounds_file (a pathlike object or string representing an existing file) – Output confounds file.

  • confounds_list (a list of items which are a string) – List of headers.

class GatherConfounds(from_file=None, resource_monitor=None, **inputs)[source]

Bases: SimpleInterface

Combine various sources of confounds in one TSV file.

Optional Inputs:
  • dvars (a pathlike object or string representing an existing file) – File containing DVARS.

  • fd (a pathlike object or string representing an existing file) – Input framewise displacement.

  • motion (a pathlike object or string representing an existing file) – Input motion parameters.

  • rmsd (a pathlike object or string representing an existing file) – Input RMS framewise displacement.

  • signals (a pathlike object or string representing an existing file) – Input signals.

  • std_dvars (a pathlike object or string representing an existing file) – File containing standardized DVARS.

Outputs:
  • confounds_file (a pathlike object or string representing an existing file) – Output confounds file.

  • confounds_list (a list of items which are a string) – List of headers.

class NormalizeMotionParams(from_file=None, resource_monitor=None, **inputs)[source]

Bases: SimpleInterface

Convert input motion parameters into the designated convention.

From niworkflows.interfaces.confounds.NormalizeMotionParams.

NOTE: Modified by Taylor Salo to support 1D arrays.

Mandatory Inputs:

in_file (a pathlike object or string representing an existing file) – The input parameters file.

Optional Inputs:

format (‘FSL’ or ‘AFNI’ or ‘FSFAST’ or ‘NIPY’) – Output format. (Nipype default value: FSL)

Outputs:

out_file (a pathlike object or string representing an existing file) – Written file path.