I am trying to import DTI data (connectome nifti format) into slicer with the DWI NiftiFSL to Nrrd Converter (Mac OS X 10.12.6, Slicer 4.9). It runs for 120s, but completes with errors*.
*Diffusion-weighted DICOM Import (DWIConvert) standard error:
libc++abi.dylib: terminating with uncaught exception of type itk::ExceptionObject: /Users/kitware/Dashboards/Nightly/Slicer-0-build/BRAINSTools/DWIConvert/DWIConvertLib.cxx:108:
itk::ERROR: Exception creating converter
itk::ExceptionObject (0x103e03ae8)
Location: "unknown"
File: /Users/kitware/Dashboards/Nightly/Slicer-0-build/BRAINSTools/DWIConvert/DWIConverter.cxx
Line: 220
Description: itk::ERROR: Mismatch between count of B Vectors (1) and B Values (143)
I already tried to reformat the bval and bvec files into columns (delimiter ‘,’ or ’ '), but it still doesn’t work.
Can you tell me, in what format the bval and bvec files have to be to work?
What tool did you use to create your NIfTI file(s)? There are several flavors of NIfTI-dwi.
The format supported by DWIConvert is FSL-style, which is also the default output style of dcm2nii. Space-delimited columns, newline-delimited rows; bvec rows correspond to x/y/z column components respectively.
e.g.:
file.bval
0 1000 1000 1000 ...
file.bvec
x1 x2 x3 x4 ...
y1 y2 y3 y4 ...
z1 z2 z3 z4 ...
(there is also a transpose vectors option available for compatibility with some similar software, which will have one b-value per row in file.bval, and one vector per row in file.bvec)
Thank you! That worked. I was able to load the images.
Unfortunately, I have one further question: The now imported images appear side by side when I scroll through them instead of one after the other (see video https://www.dropbox.com/s/jn6s11njj9c3w5s/nifti.mov?dl=0). How can I fix this?
Thank you again, Lorenz
I’ve seen something similar when DWIConvert loaded a NIfTI with the wrong ITK reader. It could also happen if the strides are wrong because the expected image/slice count doesn’t match the predicted image count based on the header, for some reason.
However, I’m surprised to see a coronal view in the “red” slice viewer, because that is axial by default. Did you change it to coronal? If not, perhaps that is an indication that the orientations are not being interpreted correctly. Was your data acquired as coronal slices?
I can take a look if you are able to share some (anonymized) data. If you prefer to share directly rather than publicly, please share to inorton at partners dot org from dropbox/onedrive/etc.
EDIT: also, if you share data, please indicate what software was used to convert it