[FieldTrip] head model mat contains only NaN values

gj gina.joue at univr.it
Thu May 19 18:36:38 CEST 2016


Hi FieldTrippers,

While trying to calculate a head model (FT ver.20160309), the head model 
contains only NaNs, and I get the following errors:

------------- beg error ------------
Warning: NaN detected, trying once more with slightly different vertex 
positions
 > In ft_prepare_headmodel (line 280)
Warning: No conductivity is declared, assuming standard values
 > In ft_headmodel_bemcp (line 79)
In ft_prepare_headmodel (line 281)

Warning: Matrix is singular, close to singular or badly scaled. Results 
may be inaccurate. RCOND = NaN.
 > In ft_headmodel_bemcp (line 185)
   In ft_prepare_headmodel (line 281)
------------- end error ------------



This was what I ran:

-----------
smri = ft_read_mri(smrifn); % subject's own structural MRI

cfg = [];
mri.coordsys = 'MNI';
cfg.brainthreshold = 0.5;
cfg.output = {'brain','skull','scalp'};
smri_seg = ft_volumesegment(cfg, smri);

cfg=[];
cfg.tissue={'brain','skull','scalp'};
cfg.method = 'projectmesh';
cfg.numvertices = [2400 1600 800];
mesh_hd=ft_prepare_mesh(cfg,smri_seg);

cfg = [];
cfg.method = 'bemcp';
headmodel = ft_prepare_headmodel(cfg, mesh_hd);
-----------

Not sure if this might be related, but we have head+neck MRIs and when I 
plot the meshes, I see that the "scalp" has vertices that connect planes 
internal to the brain (see images attached). I've tried different 
ft_prepare_mesh methods, different number of vertices....

Thanks in advance for any advice!
Gina
-------------- next part --------------
A non-text attachment was scrubbed...
Name: FTmesh-lat.png
Type: image/png
Size: 48876 bytes
Desc: not available
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20160519/b3ddf627/attachment-0002.png>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: FTmesh-sup.png
Type: image/png
Size: 43865 bytes
Desc: not available
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20160519/b3ddf627/attachment-0003.png>


More information about the fieldtrip mailing list