# Problem with the gradients table in the data set

**URL:** <https://discourse.slicer.org/t/problem-with-the-gradients-table-in-the-data-set/10108>\
**Category:** SlicerDMRI\
**Created:** [February 4, 2020, 3:50pm UTC](https://discourse.slicer.org/t/problem-with-the-gradients-table-in-the-data-set/10108 "2020-02-04T15:50:13Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Santiago\_Cutiller](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/santiago_cutiller/32/5909_2.png) [@Santiago\_Cutiller](https://discourse.slicer.org/u/Santiago_Cutiller)\
**Post date:** [February 4, 2020, 3:50pm UTC](https://discourse.slicer.org/t/problem-with-the-gradients-table-in-the-data-set/10108/1 "2020-02-04T15:50:13Z")

</div>

Hi!  
I am Santiago and I am working on a research project on epilepsy and diffusion tensor.  
I have a problem with the gradients table in the data set.  
When i trying use difussion brain masking I get the following error:  
Diffusion Brain Masking standard error: C:/Users/Usuario/AppData/Roaming/NA-MIC/Extensions-28257/SlicerDMRI/lib/Slicer-4.10/cli- modules/DiffusionWeightedVolumeMasking.exe: Error parsing Diffusion information, no B0 images.  
I checked the data. Gradient values ​​are strange

 ![image](https://us1.discourse-cdn.com/flex002/uploads/slicer/original/3X/1/8/1870e5fa7216b603ea70045881bc819e608e738a.jpeg)  
This error occurs only with data from a manufacturer. Is there a way to correct it?

Thanks!

---

<div class="post-metadata">

**Author:** ![zhangfanmark](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/zhangfanmark/32/4451_2.png) [@zhangfanmark](https://discourse.slicer.org/u/zhangfanmark)\
**Post date:** [February 4, 2020, 4:14pm UTC](https://discourse.slicer.org/t/problem-with-the-gradients-table-in-the-data-set/10108/2 "2020-02-04T16:14:12Z")

</div>

Hi,

Yes, the gradient table is strange. It looks all the directions are the same for the first few DW images. What module did you use to convert the data? I guess DWIConvert as you are using 4.10.  
You can try our new Dcm2niixGUI extension to convert the dicom data to nrrd, and see how it works. The new module is avaible in the nightly via the extension manager.

Regards,  
Fan

---

<div class="post-metadata">

**Author:** ![Santiago\_Cutiller](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/santiago_cutiller/32/5909_2.png) [@Santiago\_Cutiller](https://discourse.slicer.org/u/Santiago_Cutiller)\
**Post date:** [February 5, 2020, 8:34pm UTC](https://discourse.slicer.org/t/problem-with-the-gradients-table-in-the-data-set/10108/3 "2020-02-05T20:34:53Z")

</div>

Hello! Thanks for answering  
I can’t use Dcm2nii GUI but I think I identified the problem  
First I converted the DICOM files to FSL and examine the bvec file and check that there is definitely a problem with the gradient table:

_0.5607954357719934 0.5607954357719934 0.5607954357719934 0.5607954357719934 0.5607954357719934 0.5607954357719934 0.5607954357719934 0.5607954357719934 0.5607954357719934 0.5607954357719934 0.5607954357719934 0.5607954357719934 0.5607954357719934 0.5607954357719934 0.5607954357719934 0.5607954357719934 0.5607954357719934 0.5607954357719934 0.5607954357719934 0.5607954357719934 0.5607954357719934 0.5607954357719934 0.5607954357719934 0.5607954357719934 0.5607954357719934 0.5607954357719934 0.5607954357719934 0.5607954357719934 0.5607954357719934 0.5607954357719934 0.5607954357719934 0.5607954357719934 0.5607954357719934 0.5607954357719934_

_-0.5770928835459721 -0.5770928835459721 -0.5770928835459721 -0.5770928835459721 -0.5770928835459721 -0.5770928835459721 -0.5770928835459721 -0.5770928835459721 -0.5770928835459721 -0.5770928835459721 -0.5770928835459721 -0.5770928835459721 -0.5770928835459721 -0.5770928835459721 -0.5770928835459721 -0.5770928835459721 -0.5770928835459721 -0.5770928835459721 -0.5770928835459721 -0.5770928835459721 -0.5770928835459721 -0.5770928835459721 -0.5770928835459721 -0.5770928835459721 -0.5770928835459721 -0.5770928835459721 -0.5770928835459721 -0.5770928835459721 -0.5770928835459721 -0.5770928835459721 -0.5770928835459721 -0.5770928835459721 -0.5770928835459721 -0.5770928835459721_

_0.5936937619496226 0.5936937619496226 0.5936937619496226 0.5936937619496226 0.5936937619496226 0.5936937619496226 0.5936937619496226 0.5936937619496226 0.5936937619496226 0.5936937619496226 0.5936937619496226 0.5936937619496226 0.5936937619496226 0.5936937619496226 0.5936937619496226 0.5936937619496226 0.5936937619496226 0.5936937619496226 0.5936937619496226 0.5936937619496226 0.5936937619496226 0.5936937619496226 0.5936937619496226 0.5936937619496226 0.5936937619496226 0.5936937619496226 0.5936937619496226 0.5936937619496226 0.5936937619496226 0.5936937619496226 0.5936937619496226 0.5936937619496226 0.5936937619496226 0.5936937619496226_

All values are equal

Also in the bval file I saw that there is a problem with the b values

_-4.6116860184273879e+18 -4.6116860184273879e+18 -4.6116860184273879e+18 -4.6116860184273879e+18 -4.6116860184273879e+18 -4.6116860184273879e+18 -4.6116860184273879e+18 -4.6116860184273879e+18 -4.6116860184273879e+18 -4.6116860184273879e+18 -4.6116860184273879e+18 -4.6116860184273879e+18 -4.6116860184273879e+18 -4.6116860184273879e+18 -4.6116860184273879e+18 -4.6116860184273879e+18 -4.6116860184273879e+18 -4.6116860184273879e+18 -4.6116860184273879e+18 -4.6116860184273879e+18 -4.6116860184273879e+18 -4.6116860184273879e+18 -4.6116860184273879e+18 -4.6116860184273879e+18 -4.6116860184273879e+18 -4.6116860184273879e+18 -4.6116860184273879e+18 -4.6116860184273879e+18 -4.6116860184273879e+18 -4.6116860184273879e+18 -4.6116860184273879e+18 -4.6116860184273879e+18 -4.6116860184273879e+18 -4.6116860184273879e+18_

I searched in a forum for gradient tables for philips. Apparently in philips there are 3 modes: low, medium and high resolution according to the number of gradients and in turn each of them can have the “overplus” function activated or deactivated. Therefore there are six possible gradient tables. I tried several of them and got a good result with this:

_0 -0.499998 -0.499998 0.707107 -0.653288 -0.208664 0.019658 0.421225 0.689925 -0.653495 -0.292882 0.294515 0.514993 0.707102 -0.707102 -0.472486 0.555492 0.707102 -0.707107 -0.707102 0.707102 0.472486 -0.707085 -0.636392 -0.706047 -0.292882 0.292882 0.707085 0.707102 -0.706260 0.034719 0.707060 0.707107 100.000.000_

_0 -0.499998 -0.499998 -0.707107 -0.270606 -0.675630 -0.706829 -0.567950 -0.154927 -0.270675 -0.707102 -0.706411 -0.486072 -0.292882 -0.472486 -0.707102 -0.643950 -0.472486 -0.707107 -0.472486 -0.472486 -0.707102 -0.707085 -0.425181 -0.706047 -0.707102 -0.707102 -0.707085 -0.292882 -0.706260 -0.706256 -0.707060 -0.000000 100.000.000_

_0 -0.707110 0.707110 0.000000 -0.707098 -0.707095 -0.707112 -0.707109 -0.707108 -0.706880 -0.643604 -0.643619 -0.706056 -0.643604 -0.526084 -0.526084 -0.526077 -0.526084 -0.000212 0.526084 0.526084 0.526084 0.007849 0.643604 0.054730 0.643604 0.643604 0.007849 0.643604 0.048932 0.707105 0.011526 0.707107 100.000.000_

with that data I generated a bvec file, also generate a bval file:

_0 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000_

Then with DWIconverter I transformed the FSL into nrrd, I created brain masking and I made the tensor estimate with good results

![image](https://us1.discourse-cdn.com/flex002/uploads/slicer/original/3X/d/4/d4bf5b98cf675a26c495d1e35f3148c6f4c2ae1e.png)

I made the anisotropic fraction map that showed reasonable values

![image](https://us1.discourse-cdn.com/flex002/uploads/slicer/original/3X/3/5/35122d11c5e4e4825914df12a17dee3b2ca28296.png)

However, when I do the tractography (with the same parameters I always use) the results are not good. The tracts are aberrant.

for example in this reconstruction the roi is put in the internal capsule

![image](https://us1.discourse-cdn.com/flex002/uploads/slicer/original/3X/1/4/143edd29d442acb9f798a962166cf86b452aabfc.png)

something similar happens in the corpus callosum

![image](https://us1.discourse-cdn.com/flex002/uploads/slicer/original/3X/0/6/06f1109c252c84c325f59f071a22386e53d450c8.png)

I have read that philips gradient tables acquired with the “overplus” option sometimes require a transformation procedure but I don’t know how to do it

I’d appreciate the answer

---

<div class="post-metadata">

**Author:** ![zhangfanmark](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/zhangfanmark/32/4451_2.png) [@zhangfanmark](https://discourse.slicer.org/u/zhangfanmark)\
**Post date:** [February 5, 2020, 9:07pm UTC](https://discourse.slicer.org/t/problem-with-the-gradients-table-in-the-data-set/10108/4 "2020-02-05T21:07:09Z")

</div>

Hi, it looks like an orientation issue, but I am not sure exactly. Perhaps you can look up the fsl website for information about flipping the orientations: [https://fsl.fmrib.ox.ac.uk/fsl/fslwiki/Fslutils](https://fsl.fmrib.ox.ac.uk/fsl/fslwiki/Fslutils)
