aslprep.interfaces.utility module

Utility interfaces for ASLPrep.

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

Bases: SimpleInterface

Combine motion parameter files from MCFLIRT across image types.

Optional Inputs:
  • aslcontext (a pathlike object or string representing an existing file)

  • cbf_mat_files (a list of items which are a pathlike object or string representing an existing file or None)

  • cbf_par_file (a pathlike object or string representing an existing file or None)

  • control_mat_files (a list of items which are a pathlike object or string representing an existing file or None)

  • control_par_file (a pathlike object or string representing an existing file or None)

  • deltam_mat_files (a list of items which are a pathlike object or string representing an existing file or None)

  • deltam_par_file (a pathlike object or string representing an existing file or None)

  • label_mat_files (a list of items which are a pathlike object or string representing an existing file or None)

  • label_par_file (a pathlike object or string representing an existing file or None)

  • m0scan_mat_files (a list of items which are a pathlike object or string representing an existing file or None)

  • m0scan_par_file (a pathlike object or string representing an existing file or None)

  • m0type (a string)

  • processing_target (a string)

Outputs:
  • combined_par_file (a pathlike object or string representing an existing file)

  • mat_file_list (a list of items which are a pathlike object or string representing an existing file)

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

Bases: SimpleInterface

Run rmsdiff on each contiguous pair of transform files to build a txt file of rmsd values.

This interface uses RMSDiff internally, which may not be a proper nipype pattern.

Mandatory Inputs:
  • in_files (a list of items which are a pathlike object or string representing an existing file) – Matrix files to compare with each other.

  • ref_file (a pathlike object or string representing an existing file) – Reference volume.

Outputs:

out_file (a pathlike object or string representing an existing file) – Output txt file.

class RMSDiff(**inputs)[source]

Bases: FSLCommand

Wrapped executable: rmsdiff.

Run rmsdiff.

Mandatory Inputs:
  • matrixfile1 (a pathlike object or string representing an existing file) – First matrix file. Maps to a command-line argument: %s (position: 0).

  • matrixfile2 (a pathlike object or string representing an existing file) – Second matrix file. Maps to a command-line argument: %s (position: 1).

  • ref_vol (a pathlike object or string representing an existing file) – Reference volume. Maps to a command-line argument: %s (position: 2).

Optional Inputs:
  • args (a string) – Additional parameters to the command. Maps to a command-line argument: %s.

  • environ (a dictionary with keys which are a bytes or None or a value of class ‘str’ and with values which are a bytes or None or a value of class ‘str’) – Environment variables. (Nipype default value: {})

  • output_type (‘NIFTI’ or ‘NIFTI_PAIR’ or ‘NIFTI_GZ’ or ‘NIFTI_PAIR_GZ’) – FSL output type.

Outputs:

rmsd (a float)

aggregate_outputs(runtime=None, needed_outputs=None)[source]

Taken from nipype.interfaces.afni.preprocess.ClipLevel.

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

Bases: SimpleInterface

Split ASL data into different files.

Mandatory Inputs:
  • asl_file (a pathlike object or string representing an existing file) – ASL file to split.

  • aslcontext (a pathlike object or string representing an existing file) – Aslcontext TSV.

Optional Inputs:
  • metadata (a dictionary with keys which are any value and with values which are any value)

  • processing_target (a string)

Outputs:
  • asl_file (a pathlike object or string representing an existing file) – Modified ASL file.

  • aslcontext (a pathlike object or string representing an existing file) – Modified aslcontext file.

  • metadata (a dictionary with keys which are any value and with values which are any value)

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

Bases: SimpleInterface

Split out a specific volume type from the ASL file.

Optional Inputs:
  • asl_file (a pathlike object or string representing an existing file)

  • aslcontext (a pathlike object or string representing an existing file)

  • volumetype (a string)

Outputs:

out_file (a pathlike object or string representing an existing file)

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

Bases: SimpleInterface

Split out just the optimal volume type for reference files from the overall ASL file.

This means grabbing M0 volumes if they’re available, or control volumes if they’re available, or deltams, or cbfs.

Optional Inputs:
  • asl_file (a pathlike object or string representing an existing file)

  • aslcontext (a pathlike object or string representing an existing file)

Outputs:

out_file (a pathlike object or string representing an existing file)