FCP-INDI / C-PAC

Configurable Pipeline for the Analysis of Connectomes
https://fcp-indi.github.io/
GNU Lesser General Public License v3.0
64 stars 41 forks source link

🐛 `ValueError: All iterfields of a MapNode have to have the same length.` #1827

Open shnizzedy opened 2 years ago

shnizzedy commented 2 years ago

Describe the bug

221108-02:49:30,241 nipype.workflow ERROR:
     Node applyxfm_func_to_standard_453.a0 failed to run on host g185.
221108-02:49:30,243 nipype.workflow ERROR:
     Saving crash info to /outputs/log/crash-20221108-024930-pab2163-applyxfm_func_to_standard_453.a0-fb926909-2501-4cdb-b551-8a00965de4f1.txt
Traceback (most recent call last):
  File "/code/CPAC/pipeline/nipype_pipeline_engine/plugins/cpac_nipype_custom.py", line 312, in _send_procs_to_workers
    num_subnodes = self.procs[jobid].num_subnodes()
  File "/usr/local/miniconda/lib/python3.7/site-packages/nipype/pipeline/engine/nodes.py", line 1310, in num_subnodes
    self._check_iterfield()
  File "/usr/local/miniconda/lib/python3.7/site-packages/nipype/pipeline/engine/nodes.py", line 1346, in _check_iterfield
    % str(self.inputs)
ValueError: All iterfields of a MapNode have to have the same length. 
args = <undefined>
default_value = 0.0
dimension = <undefined>
environ = {'NSLOTS': '1'}
float = True

Custom pipeline configuration

fmriprep_seed_16-fork.yml

%YAML 1.1
---
# CPAC Pipeline Configuration YAML file
# Version 1.8.4
#
# http://fcp-indi.github.io for more info.
#
# Tip: This file can be edited manually with a text editor for quick modifications.

FROM: default

pipeline_setup: 
  # Name for this pipeline configuration - useful for identification.
  pipeline_name: fmriprep-16-forks-seed

  output_directory: 
    quality_control:
      # Generate quality control pages containing preprocessing and derivative outputs.
      generate_quality_control_images: False

  working_directory: 
    remove_working_dir: On

  system_config: 
    random_seed: 11291993
    # Select Off if you intend to run CPAC on a single machine.
    # If set to On, CPAC will attempt to submit jobs through the job scheduler / resource manager selected below.
    on_grid: 
      SGE: 
        # SGE Parallel Environment to use when running CPAC.
        # Only applies when you are running on a grid or compute cluster using SGE.
        parallel_environment: cpac

    # The maximum amount of memory each participant's workflow can allocate.
    # Use this to place an upper bound of memory usage.
    # - Warning: 'Memory Per Participant' multiplied by 'Number o =f Participants to Run Simultaneously'
    #   must not be more than the total amount of RAM.
    # - Conversely, using too little RAM can impede the speed of a pipeline run.
    # - It is recommended that you set this to a value that when multiplied by
    #   'Number of Participants to Run Simultaneously' is as much RAM you can safely allocate.
    maximum_memory_per_participant: 3

    # Full path to the FSL version to be used by CPAC.
    # If you have specified an FSL path in your .bashrc file, this path will be set automatically.
    FSLDIR: FSLDIR

  Amazon-AWS: 
    # Enable server-side 256-AES encryption on data to the S3 bucket
    s3_encryption: On

anatomical_preproc: 
  # N4 bias field correction via ANTs
  n4_bias_field_correction: On

  acpc_alignment:

    # ACPC aligned template
    T1w_ACPC_template:

    T1w_brain_ACPC_template:

  brain_extraction:
    # using: ['3dSkullStrip', 'BET', 'UNet', 'niworkflows-ants']
    # this is a fork option
    using: [niworkflows-ants]

    FSL-BET:
      # Mask created along with skull stripping. It should be `On`, if selected functionalMasking :  ['Anatomical_Refined'] and `FSL` as skull-stripping method.
      mask_boolean: Off

    FreeSurfer-BET:
      # Template to be used for FreeSurfer-BET brain extraction in CCS-options pipeline
      T1w_brain_template_mask_ccs:

segmentation: 
  tissue_segmentation: 
    # option parameters
    FSL-FAST: 
      use_priors: 
        # Use template-space tissue priors to refine the binary tissue masks generated by segmentation.
        run: Off

        # Full path to a directory containing binarized prior probability maps.
        # These maps are included as part of the 'Image Resource Files' package available on the Install page of the User Guide.
        # It is not necessary to change this path unless you intend to use non-standard priors.
        priors_path:

      thresholding:

        # thresholding of the tissue segmentation probability maps
        # options: 'Auto', 'Custom'
        use: 'Custom'

        Custom:
          # Set the threshold value for the segmentation probability masks (CSF, White Matter, and Gray Matter)
          # The values remaining will become the binary tissue masks.
          # A good starting point is 0.95.

          # CSF (cerebrospinal fluid) threshold.
          CSF_threshold_value : 0.95

          # White matter threshold.
          WM_threshold_value : 0.95

          # Gray matter threshold.
          GM_threshold_value : 0.95

    Template_Based: 
      # These masks should be in the same space of your registration template, e.g. if
      # you choose 'EPI Template' , below tissue masks should also be EPI template tissue masks.
      #
      # Options: ['T1_Template', 'EPI_Template']
      template_for_segmentation: []

      # These masks are included as part of the 'Image Resource Files' package available
      # on the Install page of the User Guide.

      # Full path to a binarized White Matter mask.
      WHITE:

      # Full path to a binarized Gray Matter mask.
      GRAY:

      # Full path to a binarized CSF mask.
      CSF:

    ANTs_Prior_Based:
      template_brain_list:
      template_segmentation_list:
      CSF_label: []
      GM_label: []
      WM_label: []

    FreeSurfer:
      erode:
      CSF_label: []
      GM_label: []
      WM_label: []

registration_workflows: 
  anatomical_registration: 
    # The resolution to which anatomical images should be transformed during registration.
    # This is the resolution at which processed anatomical files will be output.
    resolution_for_anat: 1mm

    # Template to be used during registration.
    # It is not necessary to change this path unless you intend to use a non-standard template.
    T1w_brain_template: /code/CPAC/resources/templates/tpl-MNI152NLin2009cAsym_res-01_desc-brain_T1w.nii.gz

    # Template to be used during registration.
    # It is not necessary to change this path unless you intend to use a non-standard template.
    T1w_template: /code/CPAC/resources/templates/mni_icbm152_t1_tal_nlin_asym_09c.nii

    # Template to be used during registration.
    # It is not necessary to change this path unless you intend to use a non-standard template.
    T1w_brain_template_mask: /code/CPAC/resources/templates/tpl-MNI152NLin2009cAsym_res-01_desc-brain_mask.nii.gz

    # Register skull-on anatomical image to a template.
    reg_with_skull: Off

    registration: 
      # option parameters
      ANTs: 
        # ANTs parameters for T1-template-based registration
        T1_registration: 
          - collapse-output-transforms: 1
          - dimensionality: 3
          - initial-moving-transform:
              initializationFeature: 0
          - transforms:
            - Rigid:
                convergence:
                  convergenceThreshold: 1e-06
                  convergenceWindowSize: 20
                  iteration: 100x100
                gradientStep: 0.05
                metric:
                  metricWeight: 1
                  numberOfBins: 32
                  samplingPercentage: 0.25
                  samplingStrategy: Regular
                  type: MI
                shrink-factors: 2x1
                smoothing-sigmas: 2.0x1.0vox
                use-histogram-matching: On
            - Affine:
                convergence:
                  convergenceThreshold: 1e-06
                  convergenceWindowSize: 20
                  iteration: 100x100
                gradientStep: 0.08
                metric:
                  metricWeight: 1
                  numberOfBins: 32
                  samplingPercentage: 0.25
                  samplingStrategy: Regular
                  type: MI
                shrink-factors: 2x1
                smoothing-sigmas: 1.0x0.0vox
                use-histogram-matching: On
            - SyN:
                convergence:
                  convergenceThreshold: 1e-06
                  convergenceWindowSize: 10
                  iteration: 100x70x50x20
                gradientStep: 0.1
                metric:
                  metricWeight: 1
                  radius: 4
                  type: CC
                shrink-factors: 8x4x2x1
                smoothing-sigmas: 3.0x2.0x1.0x0.0vox
                totalFieldVarianceInVoxelSpace: 0.0
                updateFieldVarianceInVoxelSpace: 3.0
                use-histogram-matching: On
                winsorize-image-intensities:
                  lowerQuantile: 0.005
                  upperQuantile: 0.995

      FSL-FNIRT: 
        # Reference mask for FSL registration.
        ref_mask:
        ref_mask_res-2:
        T1w_template_res-2:

  functional_registration: 
    coregistration: 
      func_input_prep: 
        # Choose whether to use the mean of the functional/EPI as the input to functional-to-anatomical registration or one of the volumes from the functional 4D timeseries that you choose.
        # input: ['Mean_Functional', 'Selected_Functional_Volume', 'fmriprep_reference']
        input: ['fmriprep_reference']

      boundary_based_registration: 
        # Standard FSL 5.0 Scheduler used for Boundary Based Registration.
        # It is not necessary to change this path unless you intend to use non-standard MNI registration.
        bbr_schedule: $FSLDIR/etc/flirtsch/bbr.sch

        # reference for boundary based registration
        # options: 'whole-head' or 'brain'
        reference: brain

        # choose which FAST map to generate BBR WM mask
        # options: 'probability_map', 'partial_volume_map'
        bbr_wm_map: 'partial_volume_map'

        # optional FAST arguments to generate BBR WM mask
        bbr_wm_mask_args: '-bin'

    EPI_registration: 
      ANTs: 
        # EPI registration configuration - synonymous with T1_registration
        # parameters under anatomical registration above
        parameters: 
      FSL-FNIRT: 
        # Identity matrix used during FSL-based resampling of BOLD-space data throughout the pipeline.
        # It is not necessary to change this path unless you intend to use a different template.
        identity_matrix: $FSLDIR/etc/flirtsch/ident.mat

    func_registration_to_template: 
      output_resolution: 
        # The resolution (in mm) to which the preprocessed, registered functional timeseries outputs are written into.
        # NOTE:
        #   selecting a 1 mm or 2 mm resolution might substantially increase your RAM needs- these resolutions should be selected with caution.
        #   for most cases, 3 mm or 4 mm resolutions are suggested.
        # NOTE:
        #   this also includes the single-volume 3D preprocessed functional data,
        #   such as the mean functional (mean EPI) in template space
        func_preproc_outputs: 3.438mmx3.438mmx3.4mm

        # The resolution (in mm) to which the registered derivative outputs are written into.
        # NOTE:
        #   this is for the single-volume functional-space outputs (i.e. derivatives)
        #   thus, a higher resolution may not result in a large increase in RAM needs as above
        func_derivative_outputs: 3.438mmx3.438mmx3.4mm

      target_template: 
        # option parameters
        T1_template: 
          # Standard Skull Stripped Template. Used as a reference image for functional registration.
          # This can be different than the template used as the reference/fixed for T1-to-template registration.
          T1w_brain_template_funcreg: /code/CPAC/resources/templates/tpl-MNI152NLin2009cAsym_res-02_T1w_reference.nii.gz

          # Standard Anatomical Brain Image with Skull.
          # This can be different than the template used as the reference/fixed for T1-to-template registration.
          T1w_template_funcreg: /code/CPAC/resources/templates/tpl-MNI152NLin2009cAsym_res-02_T1w_reference.nii.gz

          # Template to be used during registration.
          # It is not necessary to change this path unless you intend to use a non-standard template.
          T1w_brain_template_mask_funcreg: /code/CPAC/resources/templates/tpl-MNI152NLin2009cAsym_res-01_desc-brain_mask.nii.gz

          # a standard template for resampling if using float resolution
          T1w_template_for_resample: /code/CPAC/resources/templates/tpl-MNI152NLin2009cAsym_res-01_desc-brain_T1w.nii.gz
        EPI_template:
          # EPI template for direct functional-to-template registration
          # (bypassing coregistration and the anatomical-to-template transforms)
          EPI_template_funcreg:
          # a standard template for resampling if using float resolution
          EPI_template_for_resample:

      apply_transform:

        # options: 'default', 'abcd', 'single_step_resampling'
        # 'default': apply func-to-anat and anat-to-template transforms on motion corrected functional image.
        # 'abcd': apply motion correction, func-to-anat and anat-to-template transforms on each of raw functional volume using FSL applywarp based on ABCD-HCP pipeline.
        # 'single_step_resampling': apply motion correction, func-to-anat and anat-to-template transforms on each of raw functional volume using ANTs antsApplyTransform based on fMRIPrep pipeline.
        using: 'single_step_resampling'

functional_preproc: 
  motion_estimates_and_correction: 
    motion_estimates: 
      # calculate motion statistics BEFORE slice-timing correction
      calculate_motion_first: On

    motion_correction: 
      # using: ['3dvolreg', 'mcflirt']
      # this is a fork point
      using: ['3dvolreg']
      AFNI-3dvolreg: 

        # This option is useful when aligning high-resolution datasets that may need more alignment than a few voxels.
        functional_volreg_twopass: On

      # Choose motion correction reference. Options: mean, median, selected_volume, fmriprep_reference
      motion_correction_reference: ['fmriprep_reference']

    motion_estimate_filter:

        # Filter physiological (respiration) artifacts from the head motion estimates.
        # Adapted from DCAN Labs filter.
        #     https://www.ohsu.edu/school-of-medicine/developmental-cognition-and-neuroimaging-lab
        #     https://www.biorxiv.org/content/10.1101/337360v1.full.pdf
        # this is a fork point
        #   run: [On, Off] - this will run both and fork the pipeline
        run: [On, Off]

        # options: "notch", "lowpass"
        filter_type: "notch"

        # Number of filter coefficients.
        filter_order: 4

        # Dataset-wide respiratory rate data from breathing belt.
        # Notch filter requires either:
        #     "breathing_rate_min" and "breathing_rate_max"
        # or
        #     "center_frequency" and "filter_bandwitdh".
        # Lowpass filter requires either:
        #     "breathing_rate_min"
        # or
        #     "lowpass_cutoff".
        # If "breathing_rate_min" (for lowpass and notch filter)
        # and "breathing_rate_max" (for notch filter) are set,
        # the values set in "lowpass_cutoff" (for lowpass filter),
        # "center_frequency" and "filter_bandwidth" (for notch filter)
        # options are ignored.

        # Lowest Breaths-Per-Minute in dataset.
        # For both notch and lowpass filters.
        breathing_rate_min:

        # Highest Breaths-Per-Minute in dataset.
        # For notch filter.
        breathing_rate_max:

        # notch filter direct customization parameters

        # mutually exclusive with breathing_rate options above.
        # If breathing_rate_min and breathing_rate_max are provided,
        # the following parameters will be ignored.

        # the center frequency of the notch filter
        center_frequency: .31

        # the width of the notch filter
        filter_bandwidth: .12

        # lowpass filter direct customization parameter

        # mutually exclusive with breathing_rate options above.
        # If breathing_rate_min is provided, the following
        # parameter will be ignored.

        # the frequency cutoff of the filter
        lowpass_cutoff:

  func_masking: 
    # using: ['AFNI', 'FSL', 'FSL_AFNI', 'Anatomical_Refined', 'Anatomical_Based']
    # this is a fork point
    using: [FSL_AFNI]

    FSL_AFNI:
      bold_ref: /code/CPAC/resources/templates/tpl-MNI152NLin2009cAsym_res-02_desc-fMRIPrep_boldref.nii.gz
      brain_mask: /code/CPAC/resources/templates/tpl-MNI152NLin2009cAsym_res-02_desc-brain_mask.nii.gz
      brain_probseg: /code/CPAC/resources/templates/tpl-MNI152NLin2009cAsym_res-01_label-brain_probseg.nii.gz

  generate_func_mean:

    # Generate mean functional image
    run: On

  normalize_func:

    # Normalize functional image
    run: Off

nuisance_corrections: 
  2-nuisance_regression: 
    # this is a fork point
    #   run: [On, Off] - this will run both and fork the pipeline
    run: [On]

    # switch to Off if nuisance regression is off and you don't want to write out the regressors
    create_regressors: On

    # Select which nuisance signal corrections to apply
    Regressors: 
      - Name: 'Regressor-1'
      #1: aCompCor, GSR, no censor
        Motion:
          include_delayed: true
          include_squared: true
          include_delayed_squared: true
        aCompCor:
          summary:
            method: DetrendPC
            components: 5
          tissues:
            - WhiteMatter
            - CerebrospinalFluid
          extraction_resolution: 2
        GlobalSignal:
          summary: Mean
        PolyOrt:
          degree: 2
        Bandpass:
          bottom_frequency: 0.01
          top_frequency: 0.1
      #2 aCompCor, no GSR, no censor
      - Name: 'Regressor-2'
        Motion:
          include_delayed: true
          include_squared: true
          include_delayed_squared: true
        aCompCor:
          summary:
            method: DetrendPC
            components: 5
          tissues:
            - WhiteMatter
            - CerebrospinalFluid
          extraction_resolution: 2
        PolyOrt:
          degree: 2
        Bandpass:
          bottom_frequency: 0.01
          top_frequency: 0.1
      #3 No aCompCor, GSR, no censor
      - Name: 'Regressor-3'
        Motion:
          include_delayed: true
          include_squared: true
          include_delayed_squared: true
        GlobalSignal:
          summary: Mean
        PolyOrt:
          degree: 2
        Bandpass:
          bottom_frequency: 0.01
          top_frequency: 0.1
      #4 No aCompCor, no GSR, no censor
      - Name: 'Regressor-4'
        Motion:
          include_delayed: true
          include_squared: true
          include_delayed_squared: true
        PolyOrt:
          degree: 2
        Bandpass:
          bottom_frequency: 0.01
          top_frequency: 0.1
       #5: aCompCor, GSR, censor
      - Name: 'Regressor-5'
        Motion:
          include_delayed: true
          include_squared: true
          include_delayed_squared: true
        aCompCor:
          summary:
            method: DetrendPC
            components: 5
          tissues:
            - WhiteMatter
            - CerebrospinalFluid
          extraction_resolution: 2
        GlobalSignal:
          summary: Mean
        PolyOrt:
          degree: 2
        Bandpass:
          bottom_frequency: 0.01
          top_frequency: 0.1
        Censor:
            method: Kill
            thresholds:
              - type: FD_J
                value: 0.2
            number_of_previous_trs_to_censor: 0
            number_of_subsequent_trs_to_censor: 0 
      #6 aCompCor, no GSR, censor
      - Name: 'Regressor-6'
        Motion:
          include_delayed: true
          include_squared: true
          include_delayed_squared: true
        aCompCor:
          summary:
            method: DetrendPC
            components: 5
          tissues:
            - WhiteMatter
            - CerebrospinalFluid
          extraction_resolution: 2
        PolyOrt:
          degree: 2
        Bandpass:
          bottom_frequency: 0.01
          top_frequency: 0.1
        Censor:
            method: Kill
            thresholds:
              - type: FD_J
                value: 0.2
            number_of_previous_trs_to_censor: 0
            number_of_subsequent_trs_to_censor: 0 
      #7 No aCompCor, GSR, censor
      - Name: 'Regressor-7'
        Motion:
          include_delayed: true
          include_squared: true
          include_delayed_squared: true
        GlobalSignal:
          summary: Mean
        PolyOrt:
          degree: 2
        Bandpass:
          bottom_frequency: 0.01
          top_frequency: 0.1
        Censor:
            method: Kill
            thresholds:
              - type: FD_J
                value: 0.2
            number_of_previous_trs_to_censor: 0
            number_of_subsequent_trs_to_censor: 0 
      #8 No aCompCor, no GSR, censor
      - Name: 'Regressor-8'
        Motion:
          include_delayed: true
          include_squared: true
          include_delayed_squared: true
        PolyOrt:
          degree: 2
        Bandpass:
          bottom_frequency: 0.01
          top_frequency: 0.1
        Censor:
            method: Kill
            thresholds:
              - type: FD_J
                value: 0.2
            number_of_previous_trs_to_censor: 0
            number_of_subsequent_trs_to_censor: 0 

    # Standard Lateral Ventricles Binary Mask
    # used in CSF mask refinement for CSF signal-related regressions
    lateral_ventricles_mask: 
    # Process and refine masks used to produce regressors and time series for
    # regression.

    bandpass_filtering_order: 'After'

    regressor_masks: 
      erode_anatomical_brain_mask: 
        # Erode binarized anatomical brain mask. If choosing True, please also set seg_csf_use_erosion: True; regOption: niworkflows-ants.
        run: On

      erode_csf: 
        # Erode binarized csf tissue mask.
        run: On

      erode_wm: 
        # Erode WM binarized tissue mask.
        run: On

# OUTPUTS AND DERIVATIVES
# -----------------------
post_processing:

  spatial_smoothing:

    # Smooth the derivative outputs.
    # Set as ['nonsmoothed'] to disable smoothing. Set as ['smoothed', 'nonsmoothed'] to get both.
    #
    # Options:
    #     ['smoothed', 'nonsmoothed']
    output: ['smoothed']

    # Tool to use for smoothing.
    # 'FSL' for FSL MultiImageMaths for FWHM provided
    # 'AFNI' for AFNI 3dBlurToFWHM for FWHM provided
    smoothing_method: ['FSL']

    # Full Width at Half Maximum of the Gaussian kernel used during spatial smoothing.
    # this is a fork point
    #   i.e. multiple kernels - fwhm: [4,6,8]
    fwhm: [4]

  z-scoring:

    # z-score standardize the derivatives. This may be needed for group-level analysis.
    # Set as ['raw'] to disable z-scoring. Set as ['z-scored', 'raw'] to get both.
    #
    # Options:
    #     ['z-scored', 'raw']
    output: ['z-scored']

timeseries_extraction: 
  run: On

  tse_roi_paths:
    /ndmg_atlases/label/Human/Schaefer200_space-MNI152NLin6_res-1x1x1.nii.gz: Avg
    /ndmg_atlases/label/Human/Schaefer400_space-MNI152NLin6_res-1x1x1.nii.gz: Avg

# Functional time-series and ROI realignment method: ['ROI_to_func'] or ['func_to_ROI']
# 'ROI_to_func' will realign the atlas/ROI to functional space (fast)
# 'func_to_ROI' will realign the functional time series to the atlas/ROI space
#
#     NOTE: in rare cases, realigning the ROI to the functional space may
#           result in small misalignments for very small ROIs - please double
#           check your data if you see issues
  realignment: 'ROI_to_func'

  connectivity_matrix:
  # Create a connectivity matrix from timeseries data

  # Options:
  #  ['AFNI', 'Nilearn', 'ndmg']
    using:
      - Nilearn
      - ndmg
    # Options:
    #  ['Pearson', 'Partial']
    # Note: These options are not configurable for ndmg, which will ignore these options
    measure:
      - Pearson
      - Partial

seed_based_correlation_analysis: 
  # SCA - Seed-Based Correlation Analysis
  # For each extracted ROI Average time series, CPAC will generate a whole-brain correlation map.
  # It should be noted that for a given seed/ROI, SCA maps for ROI Average time series will be the same.
  run: Off

amplitude_low_frequency_fluctuation: 
  # ALFF & f/ALFF
  # Calculate Amplitude of Low Frequency Fluctuations (ALFF) and and fractional ALFF (f/ALFF) for all voxels.
  run: Off

regional_homogeneity: 
  # ReHo
  # Calculate Regional Homogeneity (ReHo) for all voxels.
  run: Off

voxel_mirrored_homotopic_connectivity: 
  # VMHC
  # Calculate Voxel-mirrored Homotopic Connectivity (VMHC) for all voxels.
  run: Off

  symmetric_registration: 
    # Included as part of the 'Image Resource Files' package available on the Install page of the User Guide.
    # It is not necessary to change this path unless you intend to use a non-standard symmetric template.
    T1w_brain_template_symmetric:

    # A reference symmetric brain template for resampling
    T1w_brain_template_symmetric_for_resample:

    # Included as part of the 'Image Resource Files' package available on the Install page of the User Guide.
    # It is not necessary to change this path unless you intend to use a non-standard symmetric template.
    T1w_template_symmetric:

    # A reference symmetric skull template for resampling
    T1w_template_symmetric_for_resample:

    # Included as part of the 'Image Resource Files' package available on the Install page of the User Guide.
    # It is not necessary to change this path unless you intend to use a non-standard symmetric template.
    dilated_symmetric_brain_mask:

    # A reference symmetric brain mask template for resampling
    dilated_symmetric_brain_mask_for_resample:

network_centrality: 
  # Calculate Degree, Eigenvector Centrality, or Functional Connectivity Density.
  run: Off

  # Maximum amount of RAM (in GB) to be used when calculating Degree Centrality.
  # Calculating Eigenvector Centrality will require additional memory based on the size of the mask or number of ROI nodes.
  memory_allocation: 3.0

  # Full path to a NIFTI file describing the mask. Centrality will be calculated for all voxels within the mask.
  template_specification_file:

  eigenvector_centrality: 
    # Enable/Disable eigenvector centrality by selecting the connectivity weights
    #   weight_options: ['Binarized', 'Weighted']
    # disable this type of centrality with:
    #   weight_options: []
    weight_options: [Binarized, Weighted]

  local_functional_connectivity_density: 
    # Select the type of threshold used when creating the lFCD adjacency matrix.
    # options:
    #   'Significance threshold', 'Correlation threshold'
    correlation_threshold_option: Significance threshold

    # Based on the Threshold Type selected above, enter a Threshold Value.
    # P-value for Significance Threshold
    # Sparsity value for Sparsity Threshold
    # Pearson's r value for Correlation Threshold
    correlation_threshold: 0.001

# PACKAGE INTEGRATIONS
# --------------------
PyPEER: 
  # Template-space eye mask
  eye_mask_path:

Run command

No response

Expected behavior

No crash

Acceptance criteria

Screenshots

No response

C-PAC version

v1.8.4

Container platform

Singularity

Additional context

it seems like all the forks with censoring (Regressors 5-8) are hitting an error and not completing. I don’t think this is because too many volumes are being censored — when I check the sub-122317_ses-test_task-restLR_run-1_desc-preproc-8_bold.nii.gz , for example, there are still 1170 out of the original 1200 volumes.

crash-20221108-012900-pab2163-applyxfm_func_to_standard_541.a0-8fc78508-770c-409f-bdcf-6ae206469b7d.txt

crash-20221108-024930-pab2163-applyxfm_func_to_standard_453.a0-fb926909-2501-4cdb-b551-8a00965de4f1.txt

In crash-20221108-012900-pab2163-applyxfm_func_to_standard_541.a0-8fc78508-770c-409f-bdcf-6ae206469b7d.txt,

>>> len(input_image)
1170
>>> len(transforms)
1200
shnizzedy commented 2 years ago

A little bit of diagnosis here: I think the underlying issue here is the combination of

registration_workflows: 
  functional_registration: 
    func_registration_to_template: 
      apply_transform:
        # 'single_step_resampling': apply motion correction, func-to-anat and anat-to-template transforms on each of raw functional volume using ANTs antsApplyTransform based on fMRIPrep pipeline.
        using: 'single_step_resampling'

nuisance_corrections: 
  2-nuisance_regression: 
    # this is a fork point
    #   run: [On, Off] - this will run both and fork the pipeline
    run: [On]

causing a confused order of operations which should be resolved in #1761 / v1.8.5