Back to the main page.

Bug 1054 - channelposition crashes for sens from layout neuromag306all.lay because of missing.tra

Status CLOSED WORKSFORME
Reported 2011-10-18 16:58:00 +0200
Modified 2012-02-06 15:37:13 +0100
Product: FieldTrip
Component: core
Version: unspecified
Hardware: PC
Operating System: Windows
Importance: P1 normal
Assigned to: Jörn M. Horschig
URL:
Tags:
Depends on:
Blocks:
See also:

Jörn M. Horschig - 2011-10-18 16:58:35 +0200

??? Reference to non-existent field 'tra'. Error in ==> channelposition at 240 meanpnt = [meanpnt; mean(sens.coilpos(abs(sens.tra(sel1(j),:))>0.5,:), 1)]; Error in ==> fixsens at 61 chanpos = channelposition(sens, 'channel', 'all'); Error in ==> ft_prepare_neighbours at 147 sens = fixsens(sens);


Jan-Mathijs Schoffelen - 2011-10-19 15:24:13 +0200

using ft_datatype_sens rather than fixsens


Jörn M. Horschig - 2011-10-20 15:30:44 +0200

different day, same... problem ;) Using the 2-D layout to determine the neighbours reading layout from file NM122.lay the call to "ft_layoutplot" took 0 seconds and an estimated NaN MB ??? Reference to non-existent field 'tra'. Error in ==> channelposition at 189 meanpnt1 = mean(sens.pnt(abs(sens.tra(sel(1),:))>0.5,:), 1); Error in ==> ft_datatype_sens at 103 [chanpos, chanori, chanlab] = channelposition(sens, 'channel', 'all'); Error in ==> ft_prepare_neighbours at 149 sens = ft_datatype_sens(sens);


Jörn M. Horschig - 2011-10-20 15:33:34 +0200

related, see bug 1055


Jörn M. Horschig - 2011-10-20 15:39:35 +0200

the problem seems to occur on every MEG layout


Jan-Mathijs Schoffelen - 2011-10-20 15:46:49 +0200

why is a call to channelposition necessary to begin with when the input is a layout-structure?


Jörn M. Horschig - 2011-10-20 16:01:38 +0200

probably it is not, instead, as Robert suggested in bug 1055, it might be better to deal with the sens structure in ft_read_sens,ft_prepare_layout directly. not sure if this is being done. let's say, I will look into this and resolve this one and bug 1055


Jörn M. Horschig - 2011-11-23 12:19:46 +0100

seems to work now


Boris Reuderink - 2012-02-03 22:11:09 +0100

Jörn, any clue why it suddenly started working? It should not be this magical..


Jörn M. Horschig - 2012-02-06 13:53:36 +0100

there was quite some work done on the whole sens structure definition, e.g. fixsens is now called in low-level functions. By this we ensure that the new sens-structure is being used in all high-level functions. I suppose that this and maybe some updating on the high-level code made this bug go away.


Boris Reuderink - 2012-02-06 15:37:13 +0100

Thanks for this elaboration. I'll close this issue.