barbrakr / CLF-python

Cortical Lesion Finder in Python (work in progress, not a medical tool)
GNU General Public License v3.0
1 stars 1 forks source link

file path not specified correctly #3

Closed barbrakr closed 4 years ago

barbrakr commented 4 years ago

Traceback (most recent call last): File "CLF-python/CLF/example_workflow.py", line 93, in fslmaths.inputs.in_file = opj(test,'aal_realinterest.nii') File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/nipype/interfaces/base/traits_extension.py", line 324, in validate value = super(File, self).validate(objekt, name, value, return_pathlike=True) File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/nipype/interfaces/base/traits_extension.py", line 129, in validate self.error(objekt, name, str(value)) File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/traits/trait_handlers.py", line 236, in error object, name, self.full_info(object, name, value), value traits.trait_errors.TraitError: The 'in_file' trait of a MultiImageMathsInput instance must be a pathlike object or string representing an existing file, but a value of 'CLF-python/aal_realinterest.nii' <class 'str'> was specified.

barbrakr commented 4 years ago

CLF-python expects to be run from the same level that the aal_realinterest.nii file is in, that solves this problem. I.e.

cd CLF-python python3.7 CLF/example_workflow.py