Import MRI error

Hi everyone!

I am getting the following error when I try to import the MRI on my subject´s anatomy folder:

Line 625:
Matrix dimensions must agree.
Call stack:

spm_dicom_convert.m>WriteVolumeat625
spm_dicom_convert.m>ConvertStandardat246
›spm_dicom_convert.m at 72
in_ mri dicom _spm.m at 73
import_mri.m at 111
bst call.m at 28
›tree_callbacks.m>@(h,ev)bst_call(@import_mri,iSubject,ll,(l,1)at563

This error is only for this MRI, because I have imported many others without problem.

Can you please help me?

Camilo.

This error is coming from SPM, not Brainstorm.
Can you share the DICOM files you want to convert, so that we can test it on our end and possibly relay your bug report to the SPM team?

Thanks

Thank you for the example file.

I confirm that the problem is coming from SPM12 function spm_dicom_convert.m.
I reported the bug here: Bug in DICOM import: MRScaleSlope/MRScaleIntercept with more than 1 value · Issue #5 · spm/spm · GitHub

While this gets fixed in SPM, you can use other programs to convert your DICOM folders into .nii files.
I tested your data with MRIcron / dcm2niix, and it works.
Download and install MRIcron, start the program, and select the menu Import > Convert DICOM to NIfTI.

Dear Francois

It worked perfectly! Thanks!

Camilo