Dear all,
I have been (almost) successfully recording eyetracking data with an SMI HiSpeed eyetracker.
I use a two computer setup: the first [fairly old] computer manages the eyetracker, the second computer runs PsychoPy 1.82.01 to show stimuli and to record a HDF5 file data with eyetracking samples thanks to iohub (for some obscure reason, I couldn’t get the eyetracker/experiment to work with 1.84.02, but my question here is not about this point). The two computers are communicating through Ethernet.
My problem is: I only get around 94-95% of the samples in my HDF5 file (whereas 100% of the samples are present when I save with the iView X program the last data stored in the buffer on the computer that takes care of the eyetracker). I was able to determine this by inspecting the HDF5 file, the timestamps between successive samples and the number of samples I should get according to the duration between my trial start and my trial end. The samples are recorded every 2ms - more or less (as sampling rate = 500 Hz) - but from time to time, 3 or more samples are missing in a row.
Other than this problem, everything is fine, I don’t get any error message when I run the experiment.
Do you have any idea of what could be creating this problem?
Do you know of a test I could run to find out what is going wrong: Whether it is a communication problem, a CPU/RAM problem, a programming problem (because of my bad programming) which creates some latency/overwhelms the 2nd computer?
Thank you in advance!
Coco
Configuration:
Eyetracker: SMI HiSpeed @ 500 Hz (binocular)
1st computer (SMI): OS: Windows XP, CPU: Pentium D 3.4GHz, RAM: 2GB; ethernet: Intel 82566DC Gigabit Network Connection; running iView X 2.8.26
2nd computer (PsychoPy): I tried 2 different ones and had the same problem:
2a) OS: Windows 7 64bits, CPU: i5-2450M @ 2.5GHz, RAM: 4GB; ethernet: Intel 82579LM Gigabit Network Connection; running PsychoPy 1.82.01
2b) OS: Windows 10 64bits, CPU: i5-4300U @ 1.9GHz, RAM: 8GB; ethernet: Intel Ethernet Connection I218-LM; running PsychoPy 1.82.01.
My script is based on the gc_cursor_demo - which seems ok to me, except for a redundancy between lines 194 and 212 and also the following:
kb.waitForPresses()
which returns the error:
AttributeError(<psychopy.iohub.client.ioHubDeviceView object at 0x0A47A430>, ‘waitForPresses’)
So I replaced it by the following (or something comparable):
while not kb.getEvents():
self.hub.wait(0.2))