Reply To: Only do distortion correction

Forums Forums BrainSuite Diffusion Pipeline (BDP) Only do distortion correction Reply To: Only do distortion correction

#2019
miguel_rivas
Participant

Dear sychoi,

Thank your for your reply, I tried to run the bdp.sh script using as input the T1 (skullstripped and bias field corrected) and a 4D image with the 246 bold volumes following (I think) your recommendations. As you said, for the bvals and bvecs files I created:

bvals file: matrix with 3 rows and 246 columns
bvecs file: matrix with 1 row and 246 columns

When I ran the script everything worked fine but stopped with the following error:

rmnlab1:bdp neucoga$ bash bdp.sh /Applications/BrainSuite19a/bdp/sujetos/T1_image.bfc.nii.gz –tensor –nii /Applications/BrainSuite19a/bdp/sujetos/fmri.nii.gz -g /Applications/BrainSuite19a/bdp/sujetos/bvecs -b /Applications/BrainSuite19a/bdp/sujetos/bvals

BDP Version: 19a (build #0074), released 2019-02-14

================================================================================
Setting up dataset and inputs
================================================================================
Reading input flags…

Checking input files…

BDP could not find any .mask.nii.gz file. BDP will use input bfc file itself as
brain mask for registration and statistics. All voxels with intensity>0 in bfc
will be treated as voxels in brain. You can specify a custom brain mask by using
flag –t1-mask <maskfile_name>. The custom mask must overlay correctly with
input BFC image in BrainSuite.

Processing data with fileprefix:
/Applications/BrainSuite19a/bdp/sujetos/T1_image

================================================================================
Co-registration and Distortion Correction
================================================================================
Reading the input parameters for co-registration…
Total physical memory found: 64.00GB

Checking orientation information…Done
Extracting 0-diffusion (b=0) image from input DWIs…

DWI mask is not defined in input flags. BDP will try to estimate a (pseudo) mask
from 0-diffusion (b=0) image. Automatic mask estimation may not be accurate in
some sitations and can affect overall quality of co-registration. In case
co-registration is not accurate, you can define a DWI mask by using flag
–dwi-mask <mask_filename>. The mask can be generated and hand edited in
BrainSuite interface. This mask would be used only for registration purposes
(and not for statistics computation).
Saved (pseudo) masks: /Applications/BrainSuite19a/bdp/sujetos/T1_image.dwi.RAS.mask.nii.gz

Starting Registration based distortion Correction…
Loading data…

Starting rigid registration of input images…
Reading input data…
Setting/generating masks…
Matching centroids (approx. align)…Warning: Matrix is singular to working precision.
> In register_files_affine (line 304)
In EPI_correct_files_registration_INVERSION (line 109)
In coregister_diffusion_mprage_pipeline (line 219)
In BrainSuite_Diffusion_pipeline (line 26)
Warning: Matrix is singular to working precision.
> In register_files_affine (line 305)
In EPI_correct_files_registration_INVERSION (line 109)
In coregister_diffusion_mprage_pipeline (line 219)
In BrainSuite_Diffusion_pipeline (line 26)

Matching resolution of the images…Error using eig
Input to EIG must not contain NaN or Inf.

Error in get_original_grid_data (line 44)

Error in register_files_affine (line 313)

Error in EPI_correct_files_registration_INVERSION (line 109)

Error in coregister_diffusion_mprage_pipeline (line 219)

Error in BrainSuite_Diffusion_pipeline (line 26)

MATLAB:eig:matrixWithNaNInf

What could be the error? I have installed the Matlab 2015b runtime…

Thanks for your help.

Best regards,