<div dir="ltr"><div style>Dear Gregor,</div><div style><br></div><div style>Thank you so much for your helpful advice!</div><div style>I will try this soon and report back to you all.</div><div style><br></div><div style>Best regards,</div>
<div style>roey</div><div style><br></div><div style><br></div></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Mon, Jan 20, 2014 at 1:21 PM, Gregor Volberg <span dir="ltr"><<a href="mailto:Gregor.Volberg@psychologie.uni-regensburg.de" target="_blank">Gregor.Volberg@psychologie.uni-regensburg.de</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div style="FONT:10pt Tahoma;MARGIN:4px 4px 1px">
<div>Dear Roey,</div>
<div> </div>
<div>just two or three hints that might be helpful:</div>
<div> </div>
<div>I assume that the segmentation itself was successful; you can check this with ft_plot_vol for each of your tissues. Given that the segmentation is correct and the tissue borders are not intersecting, the error occurred during the mesh construction. I experienced that the number of triangles used for the mesh is often critical, with large numbers producing self-intersections. You could play around a bit with the number of triangles used for each compartement as specified in cfg.numvertices. Then, check the effect on the resulting volume. You do not need to call the ft_sourceanalysis for that; there is the funktion om_check_vol in the external/openmeeg folder that checks the integrity of the volumes and reports intersections or self-intersections.<br>
During the leadfield computation, OpenMEEG writes some files to the hard disk for later use. If the meshes are incorrect, then the leadfield fails and no file can be written to the disk. So the error warning on the file identifiers is presumably secondary to the mesh issue.</div>
<div> </div>
<div>Kind regards,</div>
<div>Gregor </div><span class="HOEnZb"><font color="#888888">
<div> </div>
<div><br> </div>
<div> </div>
<div>-- <br>Dr. rer. nat. Gregor Volberg <<a href="mailto:gregor.volberg@psychologie.uni-regensburg.de" target="_blank">gregor.volberg@psychologie.uni-regensburg.de</a>> ( <a href="mailto:gregor.volberg@psychologie.uni-regensburg.de" target="_blank">mailto:gregor.volberg@psychologie.uni-regensburg.de</a> )<br>
University of Regensburg<br>Institute for Experimental Psychology<br>93040 Regensburg, Germany<br>Tel: <a href="tel:%2B49%20941%20943%203862" value="+499419433862" target="_blank">+49 941 943 3862</a> <br>Fax: <a href="tel:%2B49%20941%20943%203233" value="+499419433233" target="_blank">+49 941 943 3233</a><br>
<a href="http://www.psychologie.uni-regensburg.de/Greenlee/team/volberg/volberg.html" target="_blank">http://www.psychologie.uni-regensburg.de/Greenlee/team/volberg/volberg.html</a><br>>>> Roey Schurr <<a href="mailto:roeysc@gmail.com" target="_blank">roeysc@gmail.com</a>> 19.01.2014 12:21 >>><br>
</div></font></span><div><div class="h5">
<div dir="ltr">Dear fieldtrippers,
<div><br></div>
<div>I am writing you after encountering an error using the OPENMEEG method for creating a head model, which I need for source reconstruction of EEG data (using 19 electrodes), e.g.:</div>
<div>
<div>...</div>
<div>
<div>triangles 5018 and 5129 are intersecting </div>
<div>triangles 5305 and 5781 are intersecting </div>
<div>triangles 5879 and 5907 are intersecting </div></div>
<div>!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! </div>
<div>!!!!!!!!!!! WARNING !!!!!!!!!!! </div>
<div>!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!</div>
<div>Mesh is self intersecting ! </div></div>
<div>...</div>
<div>2 meshes are intersecting !<br></div>
<div><br></div>
<div>It seems to be the same problem reported by Olivia about two years ago:<br></div>
<div><a href="http://mailman.science.ru.nl/pipermail/fieldtrip/2012-March/004881.html" target="_blank">http://mailman.science.ru.nl/pipermail/fieldtrip/2012-March/004881.html</a><br></div>
<div><br></div>
<div>In what follows I will describe the main steps in my script:</div>
<div><br></div>
<div>1) I create a segmented 'brain','skull','scalp' mri structure of the subject:</div>
<div>cfg.output = {'brain','skull','scalp'};</div>
<div>[bss_segmentedmri] = ft_volumesegment(cfg, mri);</div>
<div><br></div>
<div>2) I try using ft_sourceanalysis</div>
<div><br></div>
<div>3) which in turn tries to compute the leadfield using ft_compute_leadfield through ft_leadfield_openmeeg.</div>
<div><br></div>
<div>yes this doesn't work, and I get the following error:</div>
<div>
<div>Error using fprintf</div>
<div>Invalid file identifier. Use fopen to generate a valid file identifier.</div>
<div><br></div>
<div>Error in ft_leadfield_openmeeg (line 112)</div>
<div>fprintf(fid,'%s\t%.15f\t%.15f\t%.15f\n', sens.label{ii}, sens.chanpos(ii,:));</div></div>
<div><br></div>
<div><br></div>
<div>Since it is crucial that I use a realistic head model, do you have any suggestions?</div>
<div><br></div>
<div>Any advice would be greatly appreciated!</div>
<div>Thank you, and have a nice week,</div>
<div><br></div>
<div>roey</div></div></div></div></div>
<br>_______________________________________________<br>
fieldtrip mailing list<br>
<a href="mailto:fieldtrip@donders.ru.nl">fieldtrip@donders.ru.nl</a><br>
<a href="http://mailman.science.ru.nl/mailman/listinfo/fieldtrip" target="_blank">http://mailman.science.ru.nl/mailman/listinfo/fieldtrip</a><br></blockquote></div><br></div>