Dear Jay,

I don't see anything wrong in the steps you are following. The output of eddy does have the same number of volumes as your input (i.e. 2x 31 in your case).
Dtifit will then deal with the multiple volumes per gradient if you feed it with the combined bval and bvec files.
Is there any particular reason why you would like 31 instead of 62 volumes at that stage? because if you do then you can use applytopup command.

Best regards,
Vasilis

On 19 October 2015 at 13:55, SUBSCRIBE FSL Jay <[log in to unmask]> wrote:
Hello,

I have two DTI scans acquired in opposite phase-encoding directions (one b0 and 30 diffusion-weighted directions). I am trying to perform eddy to correct for eddy current distortions, movement and susceptibility artifacts. EDDY does not output the expected corrected and merged DTI data. The following are the steps that i have followed as instructed in the manual

1. fslroi data_raw_dtiA.nii.gz  b0_blip_up  0 1

2. fslroi data_raw_dtiP.nii.gz  b0_blip_down 0 1

3. fslmerge -t  b0_blip_up b0_up_down b0_up_down
    fslmerge -t merged_data_AP data_raw_dtiA data_raw_dtiP

4. topup --imain=b0_up_down --datain=template_list --config=b02b0.cnf --out=my_topup_output --iout=my_hifi_b0

5. fslmaths my_hifi_b0 -Tmean my_hifi_b0_avg
6. bet2 my_hifi_b0_avg my_hifi_b0_avg_BET -m -n -g -0.125

7. indx=""
    for ((i=1; i<=31; i+=1)); do indx="$indx 1"; done
    for ((i=32; i<=62; i+=1)); do indx="$indx 2"; done
    echo $indx > index.txt

8. eddy --imain=merged_data_AP --mask=my_hifi_b0_avg_BET_mask --acqp=template_list --index=index.txt --bvecs=bvecs --bvals=bvals --topup=my_topup_output --out=eddy_corrected_data

template_list consists of
0 -1 0 0.1
0  1 0 0.1
bvecs (contains 62 rows : one b0 gradient followed by 30 diffusion-weighted gradients (AP acquisition) + one b0 gradient followed by 30 diffusion-weighted gradients (PA acquisition))
bvals (contains 62 rows corresponding to bvecs)

I see that the output image file 'eddy_corrected_data' still has 62 uncorrected volumes.
Can you please tell me where in the processing steps am i doing wrong?

best wishes
Jay