<html xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40"><head><meta http-equiv=Content-Type content="text/html; charset=utf-8"><meta name=Generator content="Microsoft Word 15 (filtered medium)"><style><!--
/* Font Definitions */
@font-face
        {font-family:"Cambria Math";
        panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0cm;
        font-size:11.0pt;
        font-family:"Calibri",sans-serif;}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
.MsoChpDefault
        {mso-style-type:export-only;}
@page WordSection1
        {size:612.0pt 792.0pt;
        margin:70.85pt 70.85pt 2.0cm 70.85pt;}
div.WordSection1
        {page:WordSection1;}
--></style></head><body lang=DE link=blue vlink="#954F72" style='word-wrap:break-word'><div class=WordSection1><p class=MsoNormal>Dear Stefan,</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>thanks for your reply. At the moment I use simple "coherence" following the „whole brain connectivity“ tutorial. However, if there was a memory efficient solution for dwPLI that is also an option. If I followed the discussion correctly, this is not yet fully implemented?</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>Have you tried to parcellate your data before doing the connectivity analysis? I suspect that my problem could be related with ft_sourceinterpollate, because the output of the source analysis (avg.csd, avg.mom, avg.noisecsd, computed withels pcc) is no longer present after ft_sourceinterpolate and without the source interpolation the source parcellation doesn't work, so far my impression...</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>Thanks and best regards,</p><p class=MsoNormal>Johannes<span lang=EN-GB><o:p></o:p></span></p><p class=MsoNormal><o:p> </o:p></p><div style='mso-element:para-border-div;border:none;border-top:solid #E1E1E1 1.0pt;padding:3.0pt 0cm 0cm 0cm'><p class=MsoNormal style='border:none;padding:0cm'><b>Von: </b><a href="mailto:stefan.dvoretskii@tum.de">Stefan Dvoretskii</a><br><b>Gesendet: </b>Mittwoch, 6. Oktober 2021 17:39<br><b>An: </b><a href="mailto:fieldtrip@science.ru.nl">FieldTrip discussion list</a><br><b>Cc: </b><a href="mailto:jgehrig@med.uni-frankfurt.de">Johannes Gehrig</a>; <a href="mailto:cristina.gil@tum.de">Gil Avila, Cristina</a><br><b>Betreff: </b>Re: [FieldTrip] problem using ft_sourceparcellate</p></div><p class=MsoNormal><o:p> </o:p></p><div><p class=MsoNormal>Dear Johannes, </p><div><p class=MsoNormal><o:p> </o:p></p></div><div><p class=MsoNormal>which connectivity measure are you using? There is a potential bottleneck in the 'ft_connectivityanalysis', which can however be circumvented with custom code, at least for dwPLI. Then you won't even need to parcelate.</p></div><div><p class=MsoNormal>We are currently working to incorporate it into the Fieldtrip code.</p></div><div><p class=MsoNormal><o:p> </o:p></p></div><div><p class=MsoNormal>Best regards,</p></div><div><p class=MsoNormal>Stefan</p></div><p class=MsoNormal style='margin-bottom:12.0pt'><o:p> </o:p></p><div><div><p class=MsoNormal>пн, 4 окт. 2021 г., 11:06 Johannes Gehrig via fieldtrip <<a href="mailto:fieldtrip@science.ru.nl">fieldtrip@science.ru.nl</a>>:</p></div><blockquote style='border:none;border-left:solid #CCCCCC 1.0pt;padding:0cm 0cm 0cm 6.0pt;margin-left:4.8pt;margin-top:5.0pt;margin-right:0cm;margin-bottom:5.0pt'><div><p>Dear Fieldtrip-user,</p><p>I am facing a problem using ft_sourceinterpolate. I am following the "Whole brain connectivity and network analysis"- Tutorial and as I can not compute the connectivity directly with the source data ("out of memory") I would like to perform the source parcellation before computing the connectivity. Unfortunately (fieldtrip 20211001 and matlab2018b) ft_sourceparcellate crashes after calling it. Before computing the source data the sourcemodel was interpolated with the atlas using ft_sourceinterpolate. Therefore the amount of positions in the atlas and the source data is the same (8004).</p><p>load('atlas_MMP1.0_4k.mat'); <br>cfg = [];<br>cfg.parcellation = 'parcellation';<br>cfg.method       = 'mean';<br>cfg.parameter    = 'all'; <br>parc_sourceOn = ft_sourceparcellate(cfg, source_ON, atlas);</p><p>Error message:"<br>there are in total 8004 positions, 4544 positions are inside the brain, 8004 positions have a label<br>4544 of the positions inside the brain have a label<br>4544 of the labeled positions are inside the brain<br>0 of the positions inside the brain do not have a label<br>creating 362 parcels for parameter csd by taking the mean<br>computing parcellation<br>232           tmp(j,:,:) = cellmean1(dat(tissue==j));<br>computing parcellation for L_V1_ROI<br>Index exceeds array bounds.<br><br>Error in ft_sourceparcellate>cellmean1 (line 494)<br>y = x{1};<br><br>Error in ft_sourceparcellate (line 232)<br>          tmp(j,:,:) = cellmean1(dat(tissue==j));</p><p>"</p><p>Any help and ideas are very much appreciated!</p><p>Best regards, Johannes</p></div></blockquote></div></div><p class=MsoNormal style='margin-left:4.8pt'>_______________________________________________<br>fieldtrip mailing list<br><a href="https://mailman.science.ru.nl/mailman/listinfo/fieldtrip" target="_blank">https://mailman.science.ru.nl/mailman/listinfo/fieldtrip</a><br><a href="https://doi.org/10.1371/journal.pcbi.1002202" target="_blank">https://doi.org/10.1371/journal.pcbi.1002202<br></a></p><p class=MsoNormal><o:p> </o:p></p></div></body></html>