CSP trainer and emotiv

Working with OpenViBE signal processing scenarios and doing scenario/BCI design
Post Reply
jmann18
Posts: 8
Joined: Mon Feb 05, 2018 5:40 pm

CSP trainer and emotiv

Post by jmann18 »

Hello,

I am using an Emotiv Epoc+, and am trying to use the mi-csp-2-train-CSP tutorial.
I want to apply an offline SVM classifier to some data, since the drivers for 3.5.1 are not supported.
I mark my events in EmotivPRO and export the EDF file. I use EEGLAB to convert the EDF to GDF format.
When I run the simulation one of two things happen.

1st. When the train trigger of CSP Spatial Filter trainer is set to OVTK_GDF_End_Of_Trial, OVTK_GDF_End_Of_Session, or OVTK_StimulationId_Train nothing happens and the simulation will run forever.

2nd. When the train trigger is set to OVTK_StimulationId_EndOfFile, I get the following 0 chunk error below.

Code: Select all

[ INF ] At time 0.000 sec <Box algorithm::(0x00007cac, 0x00005021) aka GDF file reader> Found tag 3 at pos 10496 [length 43], skipping content. Could someone please shed some light?
[ INF ] At time 0.000 sec <Box algorithm::(0x00007cac, 0x00005021) aka GDF file reader> Found tag 6 at pos 10543 [length 8], skipping content.
[ INF ] At time 0.000 sec <Box algorithm::(0x00007cac, 0x00005021) aka GDF file reader> Found tag 0 at pos 10555 [length 0], skipping content.
[ INF ] At time 0.000 sec <Box algorithm::(0x00007cac, 0x00005021) aka GDF file reader> Found tag 3 at pos 10240 [length 43], skipping content.
[ INF ] At time 0.000 sec <Box algorithm::(0x00007cac, 0x00005021) aka GDF file reader> Found tag 6 at pos 10287 [length 8], skipping content.
[ INF ] At time 0.000 sec <Box algorithm::(0x00007cac, 0x00005021) aka GDF file reader> Found tag 0 at pos 10299 [length 0], skipping content.
[ INF ] At time 26.000 sec <Box algorithm::(0x00004125, 0x0000536f) aka CSP Spatial Filter Trainer> Received train stimulation - be patient
[ INF ] At time 26.000 sec <Box algorithm::(0x00004125, 0x0000536f) aka CSP Spatial Filter Trainer> Data covariance dims are [39x39]. Number of samples per condition : 
[ INF ] At time 26.000 sec <Box algorithm::(0x00004125, 0x0000536f) aka CSP Spatial Filter Trainer>   cond1 = 0 chunks, sized 128 -> 0 samples
[ INF ] At time 26.000 sec <Box algorithm::(0x00004125, 0x0000536f) aka CSP Spatial Filter Trainer>   cond2 = 0 chunks, sized 128 -> 0 samples
[ ERROR ] At time 26.000 sec <Box algorithm::(0x00004125, 0x0000536f) aka CSP Spatial Filter Trainer> No signal received... Can't continue

If someone could help, I would greatly appreciate it!

jtlindgren
Posts: 775
Joined: Tue Dec 04, 2012 3:53 pm
Location: INRIA Rennes, FRANCE

Re: CSP trainer and emotiv

Post by jtlindgren »

Hi jmann,

approach 2 is correct, after the end of the data, you need to inform the CSP Trainer Box that its time to build the model. This is done with a stimulation identifier of your choice (such as end of file); this stimulation trigger needs to be part of your recording or gdf file, its not added by openvibe afaik.

The CSP Trainer box expects to get epochs of different classes to its different inputs before you send the training trigger, so you need to make sure the data is routed correctly. Usually as many Stimulation Based Epoching boxes are used for this routing as there are classes. You can use signal display or ebml stream spy to see whats flowing in the streams. More info about doing scenario diagnostics here,

http://openvibe.inria.fr/tutorial-troub ... scenarios/

Good luck,
Jussi

jmann18
Posts: 8
Joined: Mon Feb 05, 2018 5:40 pm

Re: CSP trainer and emotiv

Post by jmann18 »

That helped quite a bit! It appears that my marked events are not being registered by the "Stimulation based epoching" box. The initial signal from the gdf file reader shows the marked events, but I receive no signals from the "Stimulation based epoching" for the left and right hand movements. When I use bci competition data-set, the training works. If I cannot get the gdf to work, do you know how I may adjust the emotiv csv format to fit openvibes csv reader?

I appreciate the help!

jtlindgren
Posts: 775
Joined: Tue Dec 04, 2012 3:53 pm
Location: INRIA Rennes, FRANCE

Re: CSP trainer and emotiv

Post by jtlindgren »

Hi, you can put a 'stimulation listener' box after the gdf reader. Does it show meaningful left/right markers in the data coming from the box?

Cheers,
Jussi

jmann18
Posts: 8
Joined: Mon Feb 05, 2018 5:40 pm

Re: CSP trainer and emotiv

Post by jmann18 »

Thank you for your help! I included the 'Stimulation listener' and was able to see the events. I simply had to re-select the stimulation labels!

Cheers

Post Reply