Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CAPS outputs were not found for some image(s): Where to find the .pklz error files #216

Closed
jmcawood opened this issue Apr 29, 2021 · 18 comments

Comments

@jmcawood
Copy link

jmcawood commented Apr 29, 2021

Disscussion was slightly off topic so I move this to a new issue #218

This disscussion was aimed at finding where the .pklz files were saved. See also #217


Hi I am new to clinica and have been slowly working through a bunch of issues however I can not solve this one. Can some one help please?

clinica run t1-volume BIDS/ test/ test-group
The t1-volume pipeline is divided into 4 parts:
t1-volume-tissue-segmentation pipeline: Tissue segmentation, bias correction and spatial normalization to MNI space
t1-volume-create-dartel pipeline: Inter-subject registration with the creation of a new DARTEL template
t1-volume-dartel2mni pipeline: DARTEL template to MNI
t1-volume-parcellation pipeline: Atlas statistics

Part 1/4: Running t1-volume-segmentation pipeline
The pipeline will be run on the following 2 image(s):
sub-S24022 | ses-01,
sub-S45030 | ses-01,
The pipeline will last approximately 10 minutes per image.

[Warning] You did not specify the number of threads to run in parallel (--n_procs argument).
Computation time can be shorten as you have 48 CPUs on this computer. We recommend using 47 threads.

How many threads do you want to use? If you do not answer within 15 sec, default value of 47 will be taken. Use --n_procs argument if you want to disable this message next time.
[00:07:15] Running pipeline for sub-S45030 | ses-01
[00:07:15] Running pipeline for sub-S24022 | ses-01

[00:12:47] Pipeline finished with errors.

CAPS outputs were not found for some image(s):
Implementation on which image(s) failed will appear soon.

Documentation can be found here: https://aramislab.paris.inria.fr/clinica/docs/public/latest/
If you need support, do not hesitate to ask: https://groups.google.com/forum/#!forum/clinica-user
Alternatively, you can also open an issue on GitHub: https://github.com/aramis-lab/clinica/issues

Here is the error file traceback


nipypecli crash crash-20210430-001245-user-3-T1wToMni.a0-c9d67331-0f44-454b-b822-fe20293f8872.pklz

File: /home/user/Documents/ADNI Data/RAW DATA/Uncompressed Data/AD/crash-20210430-001245-user-3-T1wToMni.a0-c9d67331-0f44-454b-b822-fe20293f8872.pklz
Node: t1-volume-tissue-segmentation.3-T1wToMni
Working directory: /tmp/tmp7jnpv21k/t1-volume-tissue-segmentation/da6acef93050a86f660ea26f80c21d4beb50efc7/3-T1wToMni

Node inputs:

deformation_field =
fwhm =
in_files =
interpolation =
mask = 0
matlab_cmd =
mfile = True
paths =
use_mcr =
use_v8struct = True

Traceback:
Traceback (most recent call last):
File "/home/user/miniconda3/envs/clinicaEnv/lib/python3.7/site-packages/nipype/interfaces/base/core.py", line 537, in aggregate_outputs
setattr(outputs, key, val)
File "/home/user/miniconda3/envs/clinicaEnv/lib/python3.7/site-packages/nipype/interfaces/base/traits_extension.py", line 426, in validate
value = super(MultiObject, self).validate(objekt, name, newvalue)
File "/home/user/miniconda3/envs/clinicaEnv/lib/python3.7/site-packages/traits/trait_types.py", line 2515, in validate
return TraitListObject(self, object, name, value)
File "/home/user/miniconda3/envs/clinicaEnv/lib/python3.7/site-packages/traits/trait_list_object.py", line 585, in init
notifiers=[self.notifier],
File "/home/user/miniconda3/envs/clinicaEnv/lib/python3.7/site-packages/traits/trait_list_object.py", line 213, in init
super().init(self.item_validator(item) for item in iterable)
File "/home/user/miniconda3/envs/clinicaEnv/lib/python3.7/site-packages/traits/trait_list_object.py", line 213, in
super().init(self.item_validator(item) for item in iterable)
File "/home/user/miniconda3/envs/clinicaEnv/lib/python3.7/site-packages/traits/trait_list_object.py", line 865, in _item_validator
return trait_validator(object, self.name, value)
File "/home/user/miniconda3/envs/clinicaEnv/lib/python3.7/site-packages/nipype/interfaces/base/traits_extension.py", line 330, in validate
value = super(File, self).validate(objekt, name, value, return_pathlike=True)
File "/home/user/miniconda3/envs/clinicaEnv/lib/python3.7/site-packages/nipype/interfaces/base/traits_extension.py", line 135, in validate
self.error(objekt, name, str(value))
File "/home/user/miniconda3/envs/clinicaEnv/lib/python3.7/site-packages/traits/base_trait_handler.py", line 75, in error
object, name, self.full_info(object, name, value), value
traits.trait_errors.TraitError: Each element of the 'out_files' trait of an ApplySegmentationDeformationOutput instance must be a pathlike object or string representing an existing file, but a value of '/tmp/tmp7jnpv21k/t1-volume-tissue-segmentation/da6acef93050a86f660ea26f80c21d4beb50efc7/3-T1wToMni/wsub-S24022_ses-01_T1w.nii' <class 'str'> was specified.

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/home/user/miniconda3/envs/clinicaEnv/lib/python3.7/site-packages/nipype/pipeline/plugins/multiproc.py", line 67, in run_node
result["result"] = node.run(updatehash=updatehash)
File "/home/user/miniconda3/envs/clinicaEnv/lib/python3.7/site-packages/nipype/pipeline/engine/nodes.py", line 516, in run
result = self._run_interface(execute=True)
File "/home/user/miniconda3/envs/clinicaEnv/lib/python3.7/site-packages/nipype/pipeline/engine/nodes.py", line 635, in _run_interface
return self._run_command(execute)
File "/home/user/miniconda3/envs/clinicaEnv/lib/python3.7/site-packages/nipype/pipeline/engine/nodes.py", line 741, in _run_command
result = self._interface.run(cwd=outdir)
File "/home/user/miniconda3/envs/clinicaEnv/lib/python3.7/site-packages/nipype/interfaces/base/core.py", line 436, in run
outputs = self.aggregate_outputs(runtime)
File "/home/user/miniconda3/envs/clinicaEnv/lib/python3.7/site-packages/nipype/interfaces/base/core.py", line 544, in aggregate_outputs
raise FileNotFoundError(msg)

FileNotFoundError: No such file or directory '['/tmp/tmp7jnpv21k/t1-volume-tissue-segmentation/da6acef93050a86f660ea26f80c21d4beb50efc7/3-T1wToMni/wsub-S24022_ses-01_T1w.nii']' for output 'out_files' of a ApplySegmentationDeformation interface


The file that could not be found "wsub-S24022_ses-01_T1w.nii" was created and saved in my /Documents/MATLAB/ working directory, I'm not sure if this is the issue.

@asd567
Copy link

asd567 commented Apr 30, 2021

Hi I am new to clinica and have been slowly working through a bunch of issues however I can not solve this one. Can some one help please?

clinica run t1-volume BIDS/ test/ test-group
The t1-volume pipeline is divided into 4 parts:
t1-volume-tissue-segmentation pipeline: Tissue segmentation, bias correction and spatial normalization to MNI space
t1-volume-create-dartel pipeline: Inter-subject registration with the creation of a new DARTEL template
t1-volume-dartel2mni pipeline: DARTEL template to MNI
t1-volume-parcellation pipeline: Atlas statistics

Part 1/4: Running t1-volume-segmentation pipeline
The pipeline will be run on the following 2 image(s):
sub-S24022 | ses-01,
sub-S45030 | ses-01,
The pipeline will last approximately 10 minutes per image.

[Warning] You did not specify the number of threads to run in parallel (--n_procs argument).
Computation time can be shorten as you have 48 CPUs on this computer. We recommend using 47 threads.

How many threads do you want to use? If you do not answer within 15 sec, default value of 47 will be taken. Use --n_procs argument if you want to disable this message next time.
[00:07:15] Running pipeline for sub-S45030 | ses-01
[00:07:15] Running pipeline for sub-S24022 | ses-01

[00:12:47] Pipeline finished with errors.

CAPS outputs were not found for some image(s):
Implementation on which image(s) failed will appear soon.

Documentation can be found here: https://aramislab.paris.inria.fr/clinica/docs/public/latest/
If you need support, do not hesitate to ask: https://groups.google.com/forum/#!forum/clinica-user
Alternatively, you can also open an issue on GitHub: https://github.com/aramis-lab/clinica/issues

Here is the error file traceback

nipypecli crash crash-20210430-001245-user-3-T1wToMni.a0-c9d67331-0f44-454b-b822-fe20293f8872.pklz

File: /home/user/Documents/ADNI Data/RAW DATA/Uncompressed Data/AD/crash-20210430-001245-user-3-T1wToMni.a0-c9d67331-0f44-454b-b822-fe20293f8872.pklz
Node: t1-volume-tissue-segmentation.3-T1wToMni
Working directory: /tmp/tmp7jnpv21k/t1-volume-tissue-segmentation/da6acef93050a86f660ea26f80c21d4beb50efc7/3-T1wToMni

Node inputs:

deformation_field =
fwhm =
in_files =
interpolation =
mask = 0
matlab_cmd =
mfile = True
paths =
use_mcr =
use_v8struct = True

Traceback:
Traceback (most recent call last):
File "/home/user/miniconda3/envs/clinicaEnv/lib/python3.7/site-packages/nipype/interfaces/base/core.py", line 537, in aggregate_outputs
setattr(outputs, key, val)
File "/home/user/miniconda3/envs/clinicaEnv/lib/python3.7/site-packages/nipype/interfaces/base/traits_extension.py", line 426, in validate
value = super(MultiObject, self).validate(objekt, name, newvalue)
File "/home/user/miniconda3/envs/clinicaEnv/lib/python3.7/site-packages/traits/trait_types.py", line 2515, in validate
return TraitListObject(self, object, name, value)
File "/home/user/miniconda3/envs/clinicaEnv/lib/python3.7/site-packages/traits/trait_list_object.py", line 585, in init
notifiers=[self.notifier],
File "/home/user/miniconda3/envs/clinicaEnv/lib/python3.7/site-packages/traits/trait_list_object.py", line 213, in init
super().init(self.item_validator(item) for item in iterable)
File "/home/user/miniconda3/envs/clinicaEnv/lib/python3.7/site-packages/traits/trait_list_object.py", line 213, in
super().init(self.item_validator(item) for item in iterable)
File "/home/user/miniconda3/envs/clinicaEnv/lib/python3.7/site-packages/traits/trait_list_object.py", line 865, in _item_validator
return trait_validator(object, self.name, value)
File "/home/user/miniconda3/envs/clinicaEnv/lib/python3.7/site-packages/nipype/interfaces/base/traits_extension.py", line 330, in validate
value = super(File, self).validate(objekt, name, value, return_pathlike=True)
File "/home/user/miniconda3/envs/clinicaEnv/lib/python3.7/site-packages/nipype/interfaces/base/traits_extension.py", line 135, in validate
self.error(objekt, name, str(value))
File "/home/user/miniconda3/envs/clinicaEnv/lib/python3.7/site-packages/traits/base_trait_handler.py", line 75, in error
object, name, self.full_info(object, name, value), value
traits.trait_errors.TraitError: Each element of the 'out_files' trait of an ApplySegmentationDeformationOutput instance must be a pathlike object or string representing an existing file, but a value of '/tmp/tmp7jnpv21k/t1-volume-tissue-segmentation/da6acef93050a86f660ea26f80c21d4beb50efc7/3-T1wToMni/wsub-S24022_ses-01_T1w.nii' <class 'str'> was specified.

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/home/user/miniconda3/envs/clinicaEnv/lib/python3.7/site-packages/nipype/pipeline/plugins/multiproc.py", line 67, in run_node
result["result"] = node.run(updatehash=updatehash)
File "/home/user/miniconda3/envs/clinicaEnv/lib/python3.7/site-packages/nipype/pipeline/engine/nodes.py", line 516, in run
result = self._run_interface(execute=True)
File "/home/user/miniconda3/envs/clinicaEnv/lib/python3.7/site-packages/nipype/pipeline/engine/nodes.py", line 635, in _run_interface
return self._run_command(execute)
File "/home/user/miniconda3/envs/clinicaEnv/lib/python3.7/site-packages/nipype/pipeline/engine/nodes.py", line 741, in _run_command
result = self._interface.run(cwd=outdir)
File "/home/user/miniconda3/envs/clinicaEnv/lib/python3.7/site-packages/nipype/interfaces/base/core.py", line 436, in run
outputs = self.aggregate_outputs(runtime)
File "/home/user/miniconda3/envs/clinicaEnv/lib/python3.7/site-packages/nipype/interfaces/base/core.py", line 544, in aggregate_outputs
raise FileNotFoundError(msg)

FileNotFoundError: No such file or directory '['/tmp/tmp7jnpv21k/t1-volume-tissue-segmentation/da6acef93050a86f660ea26f80c21d4beb50efc7/3-T1wToMni/wsub-S24022_ses-01_T1w.nii']' for output 'out_files' of a ApplySegmentationDeformation interface

The file that could not be found "wsub-S24022_ses-01_T1w.nii" was created and saved in my /Documents/MATLAB/ working directory, I'm not sure if this is the issue.

I have the similar error as yours. I was confused how to find *.pklz . Could you please tell me how did you find the file like thiscrash-20210430-001245-user-3-T1wToMni.a0-c9d67331-0f44-454b-b822-fe20293f8872.pklz? I will appreciate it if you can tell me.
Best,
asd567

@jmcawood
Copy link
Author

The error files were located in the directory that my terminal was open in.

@asd567
Copy link

asd567 commented Apr 30, 2021

I am sorry that I have the wrong expression. I want to know whether the *.pklz file is in your terminal automatically when the error happened

@asd567
Copy link

asd567 commented Apr 30, 2021

Or how did you find the error .pklz? Did you click every file in ADNI and BIDS and CAPS ?

@jmcawood
Copy link
Author

The error files .pklz were not automatically in my terminal.

I had a folder called AD which I started my terminal in. Within this folder was my BIDS and CAPS folder.

When the error occured, the error files appeared in my AD folder beside the BIDS and CAPS folder.

Based on this I'm assuming the error files will be created in the folder your terminal is open in.

@asd567
Copy link

asd567 commented Apr 30, 2021

I am very happy that you reply me so fast.

I am used the absolutely file root(BIDS & CAPS) , and there are no .pklz files

I have no idea about how to do the rest work , but I still concern yours problem

Best,
asd567

@jmcawood
Copy link
Author

I had a look at your issue #217. Try using a much smaller dataset so you can debug faster.

@jmcawood
Copy link
Author

@asd567 I just tried opening my terminal in a different directory and the new error files appeard there. Go to the directory that your terminal is open in, hopefully your error files will be there.

@asd567
Copy link

asd567 commented Apr 30, 2021

I put the BIDS and CAPS files in the same file according to the file format you mentioned and ran t1-volume, and the .fklz file appeared, but it was still running. The first file is BIDS and the second file is CAPS.
image

@asd567
Copy link

asd567 commented Apr 30, 2021

Thank you for your answer and your try

Best,
asd567

@jmcawood
Copy link
Author

@asd567 Did you open the error files?

@asd567
Copy link

asd567 commented Apr 30, 2021

Sorry, I am afraid that I could not open the error file. There has a information:
微信图片_20210430170614

I want to know what kind of the software you used to open this, thus I can open the file and give the informations to you

@jmcawood
Copy link
Author

In the terminal use the command

nipypecli crash filepath/filename.pklz

@asd567
Copy link

asd567 commented Apr 30, 2021

And now, I have the CAPS imagine(s) error as yours.

@jmcawood jmcawood changed the title CAPS outputs were not found for some image(s): CAPS outputs were not found for some image(s): Apr 30, 2021
@jmcawood
Copy link
Author

Do you mean the FileNotFoundError

@asd567
Copy link

asd567 commented Apr 30, 2021

I am sorry for my poor English. And I want to show you some pictures:
Screenshot from 2021-04-30 17-20-58

Screenshot from 2021-04-30 17-22-15

@jmcawood jmcawood changed the title CAPS outputs were not found for some image(s): CAPS outputs were not found for some image(s): Where to find the .pklz error files Apr 30, 2021
@jmcawood
Copy link
Author

jmcawood commented Apr 30, 2021

@asd567 I'm going to close this issue and open my issue again with a better title. I think you should create a new issue now that you know what the problem is. Include that last image and someone may be able to help us.

Cheers

@asd567
Copy link

asd567 commented Apr 30, 2021

I accept your suggestion and I will open a new issue with the last image

Best,
asd567

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants