GithubHelp home page GithubHelp logo

psychopy-eyetracker-gazepoint's Introduction

PsychoPy

PyPI version Contributor Covenant


Announcement!!

We are excited to announce that PsychoPy will be hosting a 3-day in-person code-sprint at the University of Nottingham from 15-17 April 2024. The code sprint will be an opportunity for us to get together in person and improve PsychoPy/JS. Anyone who would like to attend will need to fill out the online application by 31 January 2024. Those selected will be notified by the end of February.


PsychoPy is an open-source package for creating experiments in behavioral science. It aims to provide a single package that is:

  • precise enough for psychophysics
  • easy enough for teaching
  • flexible enough for everything else
  • able to run experiments in a local Python script or online in JavaScript

To meet these goals PsychoPy provides a choice of interface - you can use a simple graphical user interface called Builder, or write your experiments in Python code. The entire application and library are written in Python and is platform independent.

There is a range of documentation at:

Contributions

To contribute, please fork the repository, hack in a feature branch, and send a pull request. For more, see CONTRIBUTING.md and the developers documentation at https://www.psychopy.org/developers

Code Status

Dev branch: GH tests dev CodeQL (dev)

Release branch: GH tests release CodeQL (release)

More information

psychopy-eyetracker-gazepoint's People

Contributors

mdcutone avatar

Watchers

 avatar  avatar  avatar

psychopy-eyetracker-gazepoint's Issues

Gazepoint plugin not working

This does not work. I have been trying to make it work with the current distribution of psychopy (2023.2) and nothing makes sense been trying to fix it without success, and not being able to narrow it down.

My basic code:

`from psychopy import core, visual
from psychopy.iohub import launchHubServer

# Configure the eyetracker devicepip
iohub_config = {
    "eyetracker.hw.gazepoint.gp3.EyeTracker": {
        "name": "tracker",
        "enable": True,
        "save_events": True,
        "stream_events": True,
        "event_buffer_length": 1024,
        "monitor_event_types": ['BinocularEyeSampleEvent', 'FixationStartEvent', 'FixationEndEvent'],
        "calibration": {
            "target_duration": 1.25,
            "target_delay": 0.5
        },
        "model_name": "GP3",
        "manufacturer_name": "GazePoint"
    }
}

# Start the ioHub server with the configuration
io = launchHubServer(**iohub_config)
tracker = io.devices.tracker

# Setup a window for calibration
win = visual.Window(fullscr=True)

# Start the calibration process
tracker.runSetupProcedure(win)

# Main experiment code goes here

# Cleanup
win.close()
io.quit()
`

This is the error:

*** iohub warning: Display / Monitor unit type has not been set.
Error during device creation ....
Traceback (most recent call last):
File "C:\Users\cocud\anaconda3\envs\experimental\lib\site-packages\psychopy\iohub\server.py", line 715, in createNewMonitoredDevice
dev_data = self.addDeviceToMonitor(dev_cls_name, dev_conf)
File "C:\Users\cocud\anaconda3\envs\experimental\lib\site-packages\psychopy\iohub\server.py", line 849, in addDeviceToMonitor
_dconf = yload(open(dev_conf_pth, 'r'), Loader=yLoader)
FileNotFoundError: [Errno 2] No such file or directory: 'C:\Users\cocud\anaconda3\envs\experimental\lib\site-packages\psychopy\iohub\devices\eyetracker\hw\gazepoint\gp3\default_eyetracker.yaml'
Error during device creation ....
Traceback (most recent call last):
File "C:\Users\cocud\anaconda3\envs\experimental\lib\site-packages\psychopy\iohub\server.py", line 715, in createNewMonitoredDevice
dev_data = self.addDeviceToMonitor(dev_cls_name, dev_conf)
File "C:\Users\cocud\anaconda3\envs\experimental\lib\site-packages\psychopy\iohub\server.py", line 849, in addDeviceToMonitor
_dconf = yload(open(dev_conf_pth, 'r'), Loader=yLoader)
FileNotFoundError: [Errno 2] No such file or directory: 'C:\Users\cocud\anaconda3\envs\experimental\lib\site-packages\psychopy\iohub\devices\eyetracker\hw\gazepoint\gp3\default_eyetracker.yaml
During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "C:\Users\cocud\anaconda3\envs\experimental\lib\site-packages\psychopy\iohub\server.py", line 649, in _addDevices
self.createNewMonitoredDevice(dev_cls_name, dev_conf)
File "C:\Users\cocud\anaconda3\envs\experimental\lib\site-packages\psychopy\iohub\server.py", line 728, in createNewMonitoredDevice
raise ioHubError('Error during device creation ....')
psychopy.iohub.errors.ioHubError: ioHubError:
Args: ('Error during device creation ....',)

addDeviceView: Error adding class.
Traceback (most recent call last):
File "C:\Users\cocud\anaconda3\envs\experimental\lib\site-packages\psychopy\iohub\client_init
.py", line 1081, in addDeviceView
dev_import_result = import_device(dev_mod_pth, dev_cls_name)
File "C:\Users\cocud\anaconda3\envs\experimental\lib\site-packages\psychopy\iohub\devices_init
.py", line 933, in import_device
device_class = getattr(module, device_class_name)
AttributeError: module 'psychopy.iohub.devices.eyetracker.hw.gazepoint.gp3' has no attribute 'EyeTracker'
Traceback (most recent call last):
File "c:\Users\cocud\Documents\wandering-mind\SART\asdd.py", line 24, in
tracker = io.devices.tracker
AttributeError: 'ioHubDevices' object has no attribute 'tracker'

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.