"Machine learning algorithms on eye tracking trajectories to classify patients with spatial neglect"
This repository contains the code used for the paper: "Machine learning algorithms on eye tracking trajectories to classify patients with spatial neglect".
Please cite the paper if you are using either our dataset, preprocessing or model.
You can download the dataset used for the preprocessing script from this link. For a quick test of the preprocessing, we also uploaded 4 subjects (2 healthy and 2 with neglect) inside the folder.
If users are only interested in running the classification script, they can find the dataset inside the ML_Analysis/dataset_preprocessed_trajectories.
To run the preprocessing of the trajectories, users can run the following matlab script, located inside this folder:
main.m
This file loads tre trajectories from the Dataset folder and calls the preprocessing function preprocessing_one_subject.m
for every subject.
To run the classification script, users can utilize the config file config_eye_trajectories.json
located inside this folder and run the following python script:
classification_eye_trajectories.py --config config_eye_trajectories.json
The user should ensure that the paths inside the config file are correct. More details regarding the input arguments of the config file can be found inside the description of the function ml_analysis
inside the classification_eye_trajectories.py
script. For instance, if we want to classify with the Support Vector Machine instead of the CNN, the user can insert "svm" as input argument for model_to_use
.