Dwipreproc - eddy ERROR


#21

Thanks for your help on this. My data is definitely multishell. I did inspect my bvalues which are consistent for each shell - 0, 700, 2000. Curiously if I use the data is shelled option using the command;

dwipreproc DWI_dn.mif DWI_eddy_bval.mif -rpe_none -pe_dir AP -fslgrad bvecs bvals -eddy_options "--data_is_shelled " 

I now get the following error below. Any ideas to the cause of this? Thanks again for all your help.

Traceback (most recent call last):
  File "/midas-data/software/mrtrix3_25.5.17/bin/dwipreproc", line 506, in <module>
    run.command('mrconvert dwi_post_eddy' + fsl_suffix + ' result.mif' + stride_option + ' -fslgrad ' + bvecs_path + ' bvals')
  File "/midas-data/software/mrtrix3_25.5.17/lib/mrtrix3/run.py", line 61, in command
    shebang = _shebang(line[0])
  File "/midas-data/software/mrtrix3_25.5.17/lib/mrtrix3/run.py", line 329, in _shebang
    path = find_executable(exeName(item))
  File "/usr/lib64/python2.6/distutils/spawn.py", line 191, in find_executable
    if not os.path.isfile(executable):
  File "/usr/lib64/python2.6/genericpath.py", line 29, in isfile
    st = os.stat(path)
TypeError: stat() argument 1 must be encoded string without NULL bytes, not str
[trackhd@pc8-024 060443961]$ dwipreproc DWI_dn.mif DWI_eddy_bval.mif -rpe_none -pe_dir AP -fslgrad bvecs bvals -eddy_options "--data_is_shelled "

#22

I think you have to add one whitespace character after your double quotes, i.e.
" –data_is_shelled "


#23

Given this output:

It seems to me more likely that the problem might be due to using python version 2.6. As stated in the docs, we require at least version 2.7, at least for the configure & build steps… Worth trying with version 2.7 or 3.X, it might be as simple as that.


#24

Hello all,

I am having a similar issue with the ones mentioned above. When running " dwipreproc data_denoise.mif/ dwi_preprocessed.mif -rpe_none -pe_dir j- " I get the following error:

[ERROR] Command failed: eddy_openmp --imain=dwi.nii --mask=mask.nii --acqp=eddy_config.txt --index=eddy_indices.txt --bvecs=bvecs --bvals=bvals --out=dwi_post_eddy (dwipreproc:518)
dwipreproc: Output of failed command:
eddy: msg=AcqPara::AcqPara: Unrealistic read-out time
terminate called after throwing an instance of 'EDDY::EddyException'
  what():  eddy: msg=AcqPara::AcqPara: Unrealistic read-out time
dwipreproc: Changing back to original directory (/home/suminiky/Downloads/MRTRIX)
dwipreproc: Script failed while executing the command: eddy_openmp --imain=dwi.nii --mask=mask.nii --acqp=eddy_config.txt --index=eddy_indices.txt --bvecs=bvecs --bvals=bvals --out=dwi_post_eddy
dwipreproc: For debugging, inspect contents of temporary directory: /home/suminiky/Downloads/MRTRIX/dwipreproc-tmp-Y06916/

Afterwards, when running eddy in the temp folder I get this:

eddy: msg=AcqPara::AcqPara: Unrealistic read-out time
terminate called after throwing an instance of 'EDDY::EddyException'
  what():  eddy: msg=AcqPara::AcqPara: Unrealistic read-out time
Aborted (core dumped)

Any ideas on what the issue could be?

Best,
Sabina


#25

Hi Sabina,

This is in fact an unrelated error, which has been reported here. This is not an error within dwipreproc, but something that is generated within eddy that dwipreproc is simply passing along. It claims that the EPI total readout time of your data is not “realistic”, and hence there must have been some kind of error made during your data preparation.

Due to the relationship between readout time, field inhomogeneity estimation, and geometric correction of EPI distortions, you should simply be able to e.g. halve the readout times in all of your images, and processing should operate as expected. The mrconvert -set_property option should be useful for this, in addition to this development-branch documentation page (not yet part of the main documentation, but will be soon).

Rob


#26

Hi Rob,

The answer you gave me worked last time, so thank you! However, now I need to analyze a new set of data and I am yet again receiving an error, but a different one:

dwipreproc: [ERROR] Command failed: eddy_openmp --imain=dwi.nii --mask=mask.nii --acqp=eddy_config.txt --index=eddy_indices.txt --bvecs=bvecs --bvals=bvals --out=dwi_post_eddy (dwipreproc:518)
dwipreproc: Output of failed command:
I’m thrown
terminate called after throwing an instance of ‘EDDY::KMatrixException’
what():
dwipreproc: Changing back to original directory (/home/suminiky/Documents/DATA/Menzel_preop)
dwipreproc: Script failed while executing the command: eddy_openmp --imain=dwi.nii --mask=mask.nii --acqp=eddy_config.txt --index=eddy_indices.txt --bvecs=bvecs --bvals=bvals --out=dwi_post_eddy

What could be wrong this time?

Best,
Sabina


#27

Hello all,

I am having a similar issue with the ones mentioned above. When running “dwipreproc dwi_denoised.mif dwi_processed.mif -pe_dir AP -rpe_all -readout_time 0.124” I get the following error:

Command: eddy_openmp --imain=dwi.nii --mask=mask.nii --acqp=eddy_config.txt --index=eddy_indices.txt --bvecs=bvecs --bvals=bvals --topup=field --out=dwi_post_eddy
dwipreproc:
dwipreproc: [ERROR] Command failed: eddy_openmp --imain=dwi.nii --mask=mask.nii --acqp=eddy_config.txt --index=eddy_indices.txt --bvecs=bvecs --bvals=bvals --topup=field --out=dwi_post_eddy (dwipreproc:518)
dwipreproc: Output of failed command:
dwipreproc: Changing back to original directory (/home/wpy/Desktop/FBA/p01)
dwipreproc: Script failed while executing the command: eddy_openmp --imain=dwi.nii --mask=mask.nii --acqp=eddy_config.txt --index=eddy_indices.txt --bvecs=bvecs --bvals=bvals --topup=field --out=dwi_post_eddy
dwipreproc: For debugging, inspect contents of temporary directory: /home/wpy/Desktop/FBA/p01/dwipreproc-tmp-L9W43S/

Do you have any ideas of what could be wrong?

Regards,
Pinyi Wang


#28
I’m thrown
terminate called after throwing an instance of ‘EDDY::KMatrixException’
what():

This error is entirely internal to eddy; MRtrix3’s dwipreproc script is simply passing this error message from the underlying command to the user. So I can really only suggest going into the temporary directory that was preserved by the script, and attempting to invoke eddy directly. You can also manually inspect all of the files that are being provided as input to eddy, and ensure that they are sensible according to the usage of that command. If that seems to be the case, then your question should instead be posed on the FSL mailing list, as it is independent of MRtrix3.

Note: If you say to FSL that you’ve encountered this issue when trying to run an MRtrix3 script, they won’t help you. You must validate yourself that the issue is indeed with eddy, and not with MRtrix3’s wrapping thereof, and then report it as such. Alternatively, if your investigation shows that dwipreproc is providing inappropriate data to eddy, then this is precisely the information that needs to be provided here in order for the issue to be fixed within MRtrix3.

dwipreproc: Output of failed command:
dwipreproc: Changing back to original directory (/home/wpy/Desktop/FBA/p01)

In your case @PinyiWang, eddy appears to not be providing any error message to the terminal whatsoever. Nevertheless, even in this case, the same instructions as given above to @Sabina_R apply to your case also.


#29

Thanks for your response!
I will try it!

Best,
Pinyi