How do I load a Nipype results pklz file?

I’m trying to debug a workflow, and I would like to look at the result of a single node. I tried running nipypecli show result_my_node.pklz, but the result is pretty uninformative:

< object at 0x7f32cf08fe10>

I want to interact with that object and take a closer look. How can I load it in Python?

hi @nataliavelez

have you checked the _report/report.rst in the node’s working directory? It will list inputs/outputs (if the node ran successfully).

You can also load up the results interactively with the following code:

from nipype.utils.filemanip import loadpkl
res = loadpkl('path/to/pklz')