Closed shnizzedy closed 4 years ago
Possibly related: https://github.com/FCP-INDI/C-PAC/issues/1149
Traceback (most recent call last):
File "/usr/local/miniconda/lib/python3.7/site-packages/nipype/pipeline/plugins/linear.py", line 44, in run
node.run(updatehash=updatehash)
File "/usr/local/miniconda/lib/python3.7/site-packages/nipype/pipeline/engine/nodes.py", line 471, in run
result = self._run_interface(execute=True)
File "/usr/local/miniconda/lib/python3.7/site-packages/nipype/pipeline/engine/nodes.py", line 555, in _run_interface
return self._run_command(execute)
File "/usr/local/miniconda/lib/python3.7/site-packages/nipype/pipeline/engine/nodes.py", line 635, in _run_command
result = self._interface.run(cwd=outdir)
File "/usr/local/miniconda/lib/python3.7/site-packages/nipype/interfaces/base/core.py", line 521, in run
runtime = self._run_interface(runtime)
File "/code/CPAC/utils/interfaces/function.py", line 152, in _run_interface
out = function_handle(**args)
File "/code/CPAC/nuisance/nuisance.py", line 267, in gather_nuisance
raise ValueError("Regressor type Censor specified in selectors but "
ValueError: Regressor type Censor specified in selectors but the corresponding file was not found!
When we get to the block that's throwing the error
selector['Censor']
looks like
{'method': 'SpikeRegression', 'number_of_previous_trs_to_censor': 1, 'number_of_subsequent_trs_to_censor': 2, 'thresholds': [{'type': 'FD_P', 'value': 0.5}]}
which seems reasonable.
The whole selector
looks like
{
'Bandpass': {
'bottom_frequency': 0.009,
'top_frequency': 0.08
},
'Censor': {
'method': 'SpikeRegression',
'number_of_previous_trs_to_censor': 1,
'number_of_subsequent_trs_to_censor': 2,
'thresholds': [{
'type': 'FD_P',
'value': 0.5
}]
},
'CerebrospinalFluid': {
'erode_mask': True,
'extraction_resolution': 2,
'summary': {
'filter': 'Mean',
'method': 'Mean'
}
},
'GlobalSignal': {
'summary': {
'filter': 'Mean',
'method': 'Mean'
}
},
'Motion': {
'include_delayed': True,
'include_delayed_squared': True,
'include_squared': True
},
'PolyOrt': {
'degree': 2
},
'WhiteMatter': {
'erode_mask': True,
'extraction_resolution': 2,
'summary': {
'filter': 'Mean',
'method': 'Mean'
}
},
'aCompCor': {
'extraction_resolution': 2,
'summary': {
'components': 5,
'method': 'DetrendPC'
},
'tissues': ['WhiteMatter', 'CerebrospinalFluid']
}
}
Progress (I think). With the most recent image, I'm hitting the issue of empty roi_stats.csv
files mentioned in https://github.com/FCP-INDI/C-PAC/issues/1140#issuecomment-575400720 & https://github.com/FCP-INDI/C-PAC/issues/1201#issuecomment-589827997
Here's the full set of kwargs that are getting through:
{'functional_file_path': '/home/circleci/project/outputs/working/resting_preproc_A00040640_NFB3/func_preproc_afni_mean_3dvolreg_0/_scan_MSIT/func_normalize/sub-A00040640_ses-NFB3_task-MSIT_bold_calc_tshift_resample_volreg_calc_maths.nii.gz',
'selector': {'Bandpass': {'bottom_frequency': 0.009, 'top_frequency': 0.08},
'Censor': {'method': 'SpikeRegression',
'number_of_previous_trs_to_censor': 1,
'number_of_subsequent_trs_to_censor': 2,
'thresholds': [{'type': 'FD_P', 'value': 0.5}]},
'CerebrospinalFluid': {'erode_mask': True,
'extraction_resolution': 2,
'summary': {'filter': 'Mean', 'method': 'Mean'}},
'GlobalSignal': {'summary': {'filter': 'Mean', 'method': 'Mean'}},
'Motion': {'include_delayed': True,
'include_delayed_squared': True,
'include_squared': True},
'PolyOrt': {'degree': 2},
'WhiteMatter': {'erode_mask': True,
'extraction_resolution': 2,
'summary': {'filter': 'Mean', 'method': 'Mean'}},
'aCompCor': {'extraction_resolution': 2,
'summary': {'components': 5, 'method': 'DetrendPC'},
'tissues': ['WhiteMatter', 'CerebrospinalFluid']}},
'grey_matter_summary_file_path': None,
'white_matter_summary_file_path': '/home/circleci/project/outputs/working/resting_preproc_A00040640_NFB3/nuisance_regressor_1_0/_scan_MSIT/_selector_WM-2mmE-M_CSF-2mmE-M_aC-CSF+WM-2mm-DPC5_G-M_M-SDB_P-2_BP-B0.009-T0.08_C-S-1+2-FD-P0.5/WhiteMatter_mean/roi_stats.csv',
'csf_summary_file_path': '/home/circleci/project/outputs/working/resting_preproc_A00040640_NFB3/nuisance_regressor_1_0/_scan_MSIT/_selector_WM-2mmE-M_CSF-2mmE-M_aC-CSF+WM-2mm-DPC5_G-M_M-SDB_P-2_BP-B0.009-T0.08_C-S-1+2-FD-P0.5/CerebrospinalFluid_mean/roi_stats.csv',
'acompcor_file_path': '/home/circleci/project/outputs/working/resting_preproc_A00040640_NFB3/nuisance_regressor_1_0/_scan_MSIT/_selector_WM-2mmE-M_CSF-2mmE-M_aC-CSF+WM-2mm-DPC5_G-M_M-SDB_P-2_BP-B0.009-T0.08_C-S-1+2-FD-P0.5/aCompCor_DetrendPC/compcor_regressors.1D',
'tcompcor_file_path': None,
'global_summary_file_path': '/home/circleci/project/outputs/working/resting_preproc_A00040640_NFB3/nuisance_regressor_1_0/_scan_MSIT/_selector_WM-2mmE-M_CSF-2mmE-M_aC-CSF+WM-2mm-DPC5_G-M_M-SDB_P-2_BP-B0.009-T0.08_C-S-1+2-FD-P0.5/GlobalSignal_mean/roi_stats.csv',
'motion_parameters_file_path': '/home/circleci/project/outputs/working/resting_preproc_A00040640_NFB3/func_preproc_afni_mean_3dvolreg_0/_scan_MSIT/func_motion_correct_3dvolreg/sub-A00040640_ses-NFB3_task-MSIT_bold_calc_tshift_resample.1D',
'custom_file_paths': None,
'censor_file_path': None}
Describe the bug
https://github.com/shnizzedy/C-PAC/blob/33e22b281e907f1008da0371a15513047cfabd11/CPAC/pipeline/cpac_pipeline.py#L2202-L2218
Versions
Additional context This may be fixed in https://github.com/FCP-INDI/C-PAC/pull/1288