Skip to content

data loading error at data_loader.py #2

Description

@dotchang

Thank you for sharing interesting code.

I prepared BCICIV_2a_gdf data from original "https://bbci.de/competition/iv/download/".
Especially, "Data sets 2a: [ GDF files zipped (420 MB) ]"
And I downloaded A04T.mat and A04E.mat from "https://bnci-horizon-2020.eu/database/data-sets".

And I tried to run data_loader.py with small modifications that related to mne (raw_gdf.info["gdf_events"] = gdf_events -> raw_gdf.info["temp"]["gdf_events"] = gdf_events),
I got these errors,

C:\Users\yoshi\LMDA-Code>python data_loader.py
Reading 0 ... 600914 = 0.000 ... 2403.656 secs...
Used Annotations descriptions: ['1023', '1072', '32766', '768', '769', '770', '771', '772']
Traceback (most recent call last):
File "C:\Users\yoshi\LMDA-Code\data_loader.py", line 159, in
train_cnt = train_loader.load()
^^^^^^^^^^^^^^^^^^^
File "C:\Users\yoshi\LMDA-Code\data_loader.py", line 16, in load
events, artifact_trial_mask = self.extract_events(cnt)
^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\yoshi\LMDA-Code\data_loader.py", line 85, in extract_events
classes = loadmat(self.labels_filename)["classlabel"].squeeze()
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^
KeyError: 'classlabel'

So, do I use wrong data? Could you give us any hints for data downloading for preparation?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions