Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Supported by

Error in Drift correction

edited December 2016 in PyGaze

Hi,
I am getting the following error when I try to run the experiment containing drift correction:

Unexpected error

item-stack: experiment[prepare].new_pygaze_drift_correct[prepare]
exception message: pygaze_eyetracker not found
time: Tue Dec 06 17:31:53 2016
exception type: AttributeError

Traceback:
  File "C:\Program Files (x86)\OpenSesame\lib\site-packages\libqtopensesame\misc\process.py", line 140, in run
    exp.run()
  File "C:\Program Files (x86)\OpenSesame\lib\site-packages\libopensesame\experiment.py", line 413, in run
    self.items.execute(self.var.start)
  File "C:\Program Files (x86)\OpenSesame\lib\site-packages\libopensesame\item_store.py", line 90, in execute
    self.prepare(name)
  File "C:\Program Files (x86)\OpenSesame\lib\site-packages\libopensesame\item_store.py", line 122, in prepare
    self[name].prepare()
  File "C:\Program Files (x86)\OpenSesame\lib\site-packages\libopensesame\sequence.py", line 124, in prepare
    self.experiment.items.prepare(_item)
  File "C:\Program Files (x86)\OpenSesame\lib\site-packages\libopensesame\item_store.py", line 122, in prepare
    self[name].prepare()
  File "C:\Program Files (x86)\OpenSesame\lib\site-packages\share\opensesame_plugins\pygaze_drift_correct\pygaze_drift_correct.py", line 76, in prepare
    self.experiment.pygaze_eyetracker.set_draw_drift_correction_target_func(
  File "C:\Program Files (x86)\OpenSesame\lib\site-packages\libopensesame\item.py", line 238, in __getattr__
    raise AttributeError(u'%s not found' % var)
AttributeError: pygaze_eyetracker not found

I think the attribute should be 'pygaze._eyetracker' instead of pygaze_eyetracker'. Not sure though but if so kindly suggest how to correct it.

Comments

  • Hi Arpit,

    It could be that your eyetracker is set to 'dummy mode' in the pygaze_init item. The drift correction only works if you've selected the correct eye tracker in this item. Of course this means you also have to have this item somewhere in your experiment in the first place.

    Let me know if this is not the cause of the error.

    Cheers,

    Josh

  • Hi Josh,
    Thank you for the response. I was running it in Eye tribe mode as before the drift correction, use to play custom calibration script and that was working. I was using it just after the custom calibration.
    Anyways, I am no longer using it as I written a custom script for the same operation.
    Thanks anyways.

  • Hi guys,

    I think the problem is simple, but admittedly a little counterintuitive: The run phase of pygaze_init must be executed before the prepare phase of pygaze_drift_correction. If you put them both in the same sequence, this is not the case, and you get this error. Could that be it?

    Cheers,
    Sebastiaan

    There's much bigger issues in the world, I know. But I first have to take care of the world I know.
    cogsci.nl/smathot

  • Hi Sebastian,
    Actually that could be a possible explanation. Now what I am doing is, in my actual experiment I have again put the script for custom drift check after custom calibration but calls it only when needed. So here it actually runs only after running the initializing the eye tracker, thereby not getting the error.

Sign In or Register to comment.