A lightweight library for reading Eyelink Data Format files in Python.
Project description
EyeLinkIO
A lightweight library to import SR Research EDF files into Python.
This Software is currenly pre-alpha, meaning it is currently being developed: Changes to the API (function names, etc.) may occur without warning. This library has been tested with MacOS and Linux, but not Windows.
About the Eyelink Data Format
The EyeLink Data Format (EDF; not to be confused with the European Data Format) is used for storing eyetracking data from EyeLink eyetrackers. It was put forward by the company SR Research. SR Research EDF files store data in a binary format, and reading these files currently requires the eyelink-edfapi
C library that is included in the EyeLink Software Development Kit.
Dependencies
Strictly speaking, EyeLinkIO only requires Numpy, and that the user has the EyeLink Software Development Kit installed on their machine (One must create a login on the forum to access the download). For converting data to pandas DataFrames
or MNE-Python Raw
instances, you must have those respective packages installed.
Example Usage
from eyelinkio import read_edf
eyelinkio.utils import _get_test_fnames # for demonstration purposes only
fname = _get_test_fnames()[0] # Replace this function with the path to your EDF file
edf_file = read_edf(fname)
print(edf_file)
<EDF | test_raw.edf>
Version: EYELINK II 1
Eye: LEFT_EYE
Pupil unit: PUPIL_AREA
Sampling frequency: 1000.0 Hz
Calibrations: 1
Length: 66.827 seconds
# Convert to a pandas DataFrame or an MNE Raw instance
dfs = edf_file.to_pandas()
raw, calibration = edf_file.to_mne()
See the documentation for more.
Acknowledgements
This package was originally adapted from the pyeparse package (created by several of the core developers of MNE-Python). It copies much of the EDF (Eyelink Data Format) reading code.
Limitations
- Reading extra sample fields (velocity, HREF, head position etc.) from the EDF file is not yet supported.
See the Roadmap for more details.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for eyelinkio-0.2.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | bfc917b611e61c83a0eda87dd263dc558c1aedf1a7e92f76d6c03619ad42eab3 |
|
MD5 | 6a0c91bdd908629ea209078a4e41c4ae |
|
BLAKE2b-256 | e0c0e49b960e33b3f4a521cc393e9cf258f0cccb24223bdef244efbd295fcfbb |