[FieldTrip] An issure about constructing individual headmodel
wang yunhong
yunhong_wang at outlook.com
Mon Dec 25 06:25:55 CET 2023
Dear FT community,
I hope this email finds you all well.
I tried to do source reconstruction with individual sMRI. I met an issue that when using individual MRI image to construct headmodel, it looked weird that the mesh was irregular.
Error messages below:
Error using assert
vertex 69 of surface 2 is outside surface 3
Error in ft_headmodel_bemcp (line 127)
assert(inside==true, 'vertex %d of surface %d is outside surface %d', j, i, i+1);
Error in ft_prepare_headmodel (line 310)
headmodel = ft_headmodel_bemcp(geometry, 'conductivity', cfg.conductivity);
In addition, I put my processing code below:
mri = ft_read_mri('sub-001_space-MNI152NLin2009cAsym_desc-preproc_T1w.nii');
mri.coordsys = 'acpc';
cfg = [];
cfg.output = {'brain','skull','scalp'};
cfg.scalpsmooth = 8;
mri_segmented = ft_volumesegment(cfg,mri);
cfg = [];
cfg.tissue = {'brain','skull','scalp'};
cfg.method = 'projectmesh';
cfg.numvertices = [3000 2000 1000];
mri_mesh = ft_prepare_mesh(cfg,mri_segmented);
cfg = [];
cfg.method = 'bemcp';
headmodel = ft_prepare_headmodel(cfg,mri_mesh);
cfg = [];
cfg.mri = mri;
cfg.method = 'basedonmni';
cfg.templatemri = 'tpl-MNI152NLin2009cAsym_space-MNI_res-01_T1w.nii';
cfg.grid.template = 'standard_sourcemodel3d10mm.mat';
cfg.nonlinear = 'yes';
cfg.unit = 'mm';
sourcemodel = ft_prepare_sourcemodel(cfg);
Warm regards,
Yunhong
---------------------------------------
----------------------------
Wang Yun-Hong *
PhD student
Faculty of Psychology
Southwest University
Email: yunhong_wang at outlook.com<mailto:yunhong_wang at outlook.com>
2 Tiansheng Road, Beibei District,
Chongqing 400715, P. R. China
*The order of my name follows Chinese tradition,
i.e., family name is Wang, and given name is Yun-Hong.
---------------------------------------
----------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20231225/a8b86d89/attachment.htm>
More information about the fieldtrip
mailing list