Page 1 of 1

efficient processing of gazeData

PostPosted: 05 Jan 2015, 16:31
by Szymek
Hi,

I wanted to ask about ideas regarding processing eye data, in my app in short I want to show moving ball on screen, capture gaze data and show all info on line chart. (first offline after recording, in later stage online as well) The problem I stumbled into is that when in gazeListener I am reaching to form to get ball position on screen and in the same time I am saving data from eye tracker the gui can freeze for a very small moment due to mentioned processing (not to mention that Eye tribe data recording is quite peformance hungry). Despite not having to complicated login in listener the performance is quite poor...

I am using Java swing for now (tried with JavaFX but seems that it was less efficient) and Jfreechart for showing data.

Ideas that come to my mind:
- Eye Tribe API solution - is it possible to make gazeData events less frequent ? in UI i saw possibility to change Hz from 30 to 60 - but will this change something ? not to mention that in my UI this option cannot be selected
- java side solution - run them in separate threads with prioritization of GUI (tried with InvokeLater with no bigger effect)

Any ideas how to tackle this problem ?

Re: efficient processing of gazeData

PostPosted: 13 Jan 2015, 09:57
by Anders
Hi Szymek

I'll do my best to answer your questions below.

...saving data from eye tracker the gui can freeze for a very small moment...


All heavy duty processing like caching and networking should be done in seperate threads. That rule applies to most programs and is not something specific to using our SDKs. We make sure that callbacks to all listeners are done in seperate threads in the SDK, but that does not elliminate the chance that expensive processing in the callback will slow down your program. I suggest handling your caching in a seperate thread (or thread pool) or using a 3rd party API for this.

not to mention that Eye tribe data recording is quite peformance hungry


I am sorry (and supprised) to hear this. Our software is highly optimized and should not result in a noticeable overhead. If you write a short program using the Java SDK that simply activates the SDK and attaches a GazeListener and output GazeData to the console, you should not experience any overhead. If that is the case, I would like to know more about your hardware setup.

is it possible to make gazeData events less frequent ?


The metioned FPS setting decides how many gazedata frame you recieve per second. If you whish to cache less frequently, then simply tell your program to e.g. skip every other frame.

not to mention that in my UI this option cannot be selected


We release updates to our software very frequently. You should log in with the credentials you got when you recieved our Dev Kit to get the latest version. That will improve general perfomance also.

Hope this helps.

/Anders