Hi,
— possibly this is a trivial/idiotic question —
but I have the following problem; I would like to use the index instead of the value to name my output files.
I have a node with iterable,
bet = pe.Node(fsl.BET()…
bet.iterables = (“frac”,np.linspace(0.1,0.9,9))
and I want to connect it to a datasink, e.g.
workflow.connect(bet,‘out_file’,sink,’@in_file.@final’)
so… is there a way that the index of the iterator (e.g. 0 to 8 in this case) is used for the output sink directory names/file names (instead of the VALUE)?
In other words, instead of output folders like
_frac_0.100000000000000000001
_frac_0.200000000000000000001
I would like to get
frac_0
frac_1
this is just an example, but I feel it would be really handy for many things!
Thanks!
Johannes