Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 10 additions & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ classifiers = [
"Programming Language :: Python :: 3.11",
"Topic :: Scientific/Engineering",
"License :: OSI Approved :: GNU General Public License v3 or later (GPLv3+)",
]
]

dependencies = [
"psychopy", # to inspect the API
Expand Down Expand Up @@ -100,4 +100,12 @@ getter = "psychopy.__init__:getVersion"
universal = 1

[tool.psychopy-docs]
src = ["psychopy-docs"]
src = ["psychopy-docs"]

[tool.setuptools]
packages = [
"psychopy_docs"
]

[tool.setuptools.package-dir]
psychopy_docs = "utils"
70 changes: 70 additions & 0 deletions source/builder/components/EyetrackerMarkerComponent.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,70 @@
.. _eyetrackermarkercomponent:

-------------------------------
Eyetracker Marker Component
-------------------------------

Add a text marker in the hdf5 file

Categories:
Eyetracking
Works in:
PsychoPy

**Note: Since this is still in beta, keep an eye out for bug fixes.**

Parameters
-------------------------------

Basic
===============================

The required attributes of the stimulus, controlling its basic function and behaviour


.. _eyetrackermarkercomponent-startVal:
Send when...
When the Eyetracker Marker Component should start, see :ref:`startStop`.

.. _eyetrackermarkercomponent-startEstim:
Expected start (s)
If you are using frames to control timing of your stimuli, you can add an expected start time to display the component timeline in the routine.

.. _eyetrackermarkercomponent-startType:
Start type
How do you want to define your start point?

Options:

* time (s)

* frame N

* condition

.. _eyetrackermarkercomponent-durationEstim:
Expected duration (s)
If you are using frames to control timing of your stimuli, you can add an expected duration to display the component timeline in the routine.

.. _eyetrackermarkercomponent-message:
Text
Text to send to the eyetracker (128 characters max)

.. _eyetrackermarkercomponent-category:
Category
Optional grouping text for the message (32 characters max)

Data
===============================

What information about this Component should be saved?


.. _eyetrackermarkercomponent-saveStartStop:
Save onset/offset times
Store the onset/offset times in the data file (as well as in the log file).

.. _eyetrackermarkercomponent-syncScreenRefresh:
Sync timing with screen refresh
Synchronize times with screen refresh (good for visual stimuli and responses based on them)

17 changes: 9 additions & 8 deletions utils/components.py
Original file line number Diff line number Diff line change
Expand Up @@ -79,14 +79,15 @@ def createFromTemplate(cls):
categs = OrderedDict()
for ref, param in comp.params.items():
# make sure categ exists
if param.categ not in params:
params[param.categ] = []
# give categ a description if available
categs[param.categ] = ""
for srcFile in (__folder__ / "categHints").glob(param.categ + ".rst"):
categs[param.categ] = srcFile.read_text(encoding="utf-8")
# sort by category
params[param.categ].append(param)
if param.categ:
if param.categ not in params:
params[param.categ] = []
# give categ a description if available
categs[param.categ] = ""
for srcFile in (__folder__ / "categHints").glob(param.categ + ".rst"):
categs[param.categ] = srcFile.read_text(encoding="utf-8")
# sort by category
params[param.categ].append(param)
# store ref
param.ref = ref
# make sure allowedLabels/Vals is a list of strings
Expand Down
Loading