psychoinformatics-de / remodnav

Robust Eye Movement Detection for Natural Viewing
Other
59 stars 16 forks source link

Linear degree approximation based on average pixel size #17

Closed simkovic closed 3 years ago

simkovic commented 3 years ago

The size of a pixel (of a flat screen) when translated to degrees of visual angle depends non-linearly on the observer position. This is the case even if the screen-to-eye distance is fixed, say with a chin rest. The rmodnav code uses a linear approximation based on the (average) pixel size. While I personally find the linearity assumption plausible, I repeatedly get pestered by reviewers of my eye-tracking studies who request the application of the exact non-linear formula.

How do You justify the linear approximation? Is there a plan to extend the algorithm with the exact formula? If I set px2deg=1 will this allow me to input data that are already in degrees?

adswa commented 3 years ago

How do You justify the linear approximation?

Remodnav is based on Nyström et al., 2010, and if I recall correctly, this is a part of their algorithm we kept.

Is there a plan to extend the algorithm with the exact formula?

Not from our side, no, but feel free to submit a PR :)

If I set px2deg=1 will this allow me to input data that are already in degrees?

Only having briefly thought about this: The algorithm needs input data in x,y coordinates. px2deg is a factor to convert those to degrees of visual angle to calculate the amplitude and velocity. I haven't worked with eyetracking data since we wrote the algorithm so my knowledge here is rusty, but I don't think one can express visual degrees in a way that x and y coordinates are preserved, so on first, lazy thought, I think this isn't possible.

simkovic commented 3 years ago

Thanks for clarification. I took a look at remodnav/clf.py and there are three lines which use self.px2deg and in all three lines self.px2deg is used as a multiplier. So setting it to one, should not alter the computation. I'm not sure whether there is some additional functionality outside this file, but if I import the classifier directly from clf.py I think this should work.