pymovements.dataset.Dataset#
- class pymovements.dataset.Dataset(definition: str | DatasetDefinition | type[DatasetDefinition], path: str | Path | DatasetPaths)[source]#
Dataset base class.
- __init__(definition: str | DatasetDefinition | type[DatasetDefinition], path: str | Path | DatasetPaths)[source]
Initialize the dataset object.
- Parameters:
definition (str, DatasetDefinition) – Dataset definition to initialize dataset with.
path (DatasetPaths, optional) – Path to the dataset directory. You can set up a custom directory structure by passing a
DatasetPathsinstance.
Methods
__init__(definition, path)Initialize the dataset object.
Clear event DataFrame.
compute_event_properties(event_properties[, ...])Calculate an event property for and add it as a column to the event dataframe.
detect_events(method, *[, eye, clear, verbose])Detect events by applying a specific event detection method.
download(*[, extract, remove_finished, verbose])Download dataset resources.
extract([remove_finished, verbose])Extract downloaded dataset archive files.
load([events, preprocessed, subset, ...])Parse file information and load all gaze files.
load_event_files([events_dirname, extension])Load all available event files.
load_gaze_files([preprocessed, ...])Load all available gaze data files.
pix2deg([verbose])Compute gaze positions in degrees of visual angle from pixel coordinates.
pos2vel([method, verbose])Compute gaze velocites in dva/s from dva coordinates.
save([events_dirname, preprocessed_dirname, ...])Save preprocessed gaze and event files.
save_events([events_dirname, verbose, extension])Save events to files.
save_preprocessed([preprocessed_dirname, ...])Save preprocessed gaze files.
scan()Infer information from filepaths and filenames.
Attributes
pathThe path to the dataset directory.