Stimulations modification

About Brain Computer Interfaces, EEG, neurofeedback, related event announcements, jobs, etc.
Post Reply
Lorena
Posts: 68
Joined: Mon Jun 04, 2012 7:33 pm

Stimulations modification

Post by Lorena »

Hello all,

I would like to perform blink detection. In order to do the training I will need to show the subject the instructions to blink at some point. My question is, if I use the acquisition scenario provided for the motor imagery, should I need to modify the lua stimulator's code as well as the visualization obtained (in the box 'Graz visualization')? Is this las thing posible?

Thank you very much for any help!

Lorena

lbonnet
Site Admin
Posts: 417
Joined: Wed Oct 07, 2009 12:11 pm

Re: Stimulations modification

Post by lbonnet »

Hi Lorena,

The motor-imagery stimulator displays pre-defined instruction cues: cross, right arrow, left arrow and such.

If you just want to display other instruction, you may use the Display Cue Image box.
(categorie : visualizatio/presentation)

This box displays an image when receiving a defined stimulation.
The box is configurable (stimulation+image pairs to show the images / 1 stimulation to clear the screen).

You would have to create your own image, for example an image saying "blink!", and set it in the box.

Then, the same Lua Stimulator box that is used in the motor imagery scenarios can be used here.
You have to output a stimulation flow that basically says:
- show my image
- wait N seconds
- clear screen
- wait M seconds
- show my image
- ...

As it is done in the motor imagery scenarios with stimulations and timers, you may customize the Lua box to set N and M, the number of iterations, etc.

Hope this helps.

Laurent-
Follow us on twitter >> openvibebci

Checkout my (old) blog for some OpenViBE tips & tricks : here !

Lorena
Posts: 68
Joined: Mon Jun 04, 2012 7:33 pm

Re: Stimulations modification

Post by Lorena »

Thanks Laurent,

Your answer is very helpful, I will work with the Display cue image box then.

Thank you!

Lorena

Lorena
Posts: 68
Joined: Mon Jun 04, 2012 7:33 pm

Re: Stimulations modification

Post by Lorena »

Dear Laurent,

I tried doing what you told me, but when I run the scenario, the blinking image is showed for too long on the screen. Besides, it takes too long until it shows the first image. I thing this is related with the 'Baseline duration' parameter, but even if I set this parameter at 0 it takes too long.

My idea is to show the image for 2 seconds, then clear the screen for 4 seconds and start over. There are some parameters in the Graz stimulator that I don´t know what they are supposed to do, so maybe there is my problem. I attach the configurations I set for the 'Display cue image' and 'Lua Stimulator' boxes, maybe yo can tell me what I am doing wrong.

Thank you for your help!

Lorena
Attachments
configurac_lua_stim.jpg
configurac_lua_stim.jpg (70.37 KiB) Viewed 14993 times
configurac_display_cue.jpg
configurac_display_cue.jpg (37.58 KiB) Viewed 14993 times

Lorena
Posts: 68
Joined: Mon Jun 04, 2012 7:33 pm

Re: Stimulations modification

Post by Lorena »

Hi all,

I am using the Display Cue Image box for the blinkings. I wonder if I can display feedback results using this box. In the Graz visualization box I see one amplitude input, which I can´t add to the Display Cue Image box.

Thanks!

Lorena

yrenard
Site Admin
Posts: 645
Joined: Fri Sep 01, 2006 3:39 pm
Contact:

Re: Stimulations modification

Post by yrenard »

Dear Lorena,

the purpose of the display cue image is to present image stimulus based on the actual stimulations that come to the box ; what you want is a feedback box now, something close to the level measure box I believe. The display cue image is not able to provide feedback, the level measure is able to do so but is not able to display images for stimulus presentation. Maybe a combination of both boxes will match your objective (the stimulus and the feedback won't be co-localized), or maybe you'll want to merge these two boxes at the C++ level to have a single specialized box that does all the work. Two different options here.

Hope this helps,
Best regards,
Yann

Lorena
Posts: 68
Joined: Mon Jun 04, 2012 7:33 pm

Re: Stimulations modification

Post by Lorena »

Hi Yann,

That is what I wanted to know, your answer is very clear.

Thank you!

Lorena

Lorena
Posts: 68
Joined: Mon Jun 04, 2012 7:33 pm

Re: Stimulations modification

Post by Lorena »

Dear Yann,

I have 2 questions:

On one hand, regarding the level measure box, I see it shows a series of columns and rows, how should I interpret this graphic?

On the other hand, is there some documentation explaining what means each field I can set in the Lua Stimulator Box? I would like to know how to arrange the settings for my experiment.

Thanks a lot for your help!

Lorena

Lorena
Posts: 68
Joined: Mon Jun 04, 2012 7:33 pm

Re: Stimulations modification

Post by Lorena »

Any clue here?

yrenard
Site Admin
Posts: 645
Joined: Fri Sep 01, 2006 3:39 pm
Contact:

Re: Stimulations modification

Post by yrenard »

Dear Lorena,

the level measure box displays rows/columns according to the input matrix structure. If you have several channels, you might have several rows, if you have several samples, you might have several columns.

About the sitmulations, you will find all the information at the stimulation codes documentation page

Hope this helps,
Regards,
Yann

Lorena
Posts: 68
Joined: Mon Jun 04, 2012 7:33 pm

Re: Stimulations modification

Post by Lorena »

Thanks Yann! :)

Lorena
Posts: 68
Joined: Mon Jun 04, 2012 7:33 pm

Re: Stimulations modification

Post by Lorena »

Hi,

What I really need to know is what means each one of the fields that can be set in the Graz Motor Imagery BCI Stimulator Box.

Also, I think this box's code is thought to show two stimuli in a random way, is that correct? If it is, can that be modified without modifiing the box's code?

Thanks!

Lorena

yrenard
Site Admin
Posts: 645
Joined: Fri Sep 01, 2006 3:39 pm
Contact:

Re: Stimulations modification

Post by yrenard »

Dear Lorena,

the settings of the stimulator define the way events in the experiment are scheduled. For instance, it defines the number of trials, that is the number of time you will have to perform imagined left or right hand movement. It also defines the duration of the baseline, that is the time before the experiment where the user does nothing, this signal is usually used to define a neutral state for instance. It defines the duration of the instruction, of the feedback etc... May I suggest that you look at the motor imagery litterature where the Graz BCI experimental setup is well defined ?

As to the behavior of the box, yes indeed, it basically sends n random stimulations for the two expected tasks (it is actually more than that because it also sends stimulations such as "cross on screen", "continous feedback", "trial start & stop" etc - you may want to inspect what happens with a "stimulation listener" box). If you want to change the class 1/class 2 stimulation codes to something else than left and right, this can be changed as a setting of the box. If you want to change the different durations involved, it can be changed as a setting of the box as well. If you want to change the behavior as not to send stimulations randomly for instance, then you have to hack the lua script.

Lua is a very intuitive programming - scripting - language. It might be quite easy to handle :) still if you need further assistance, feel free to ask !

Hope this helps,
Best regards,
Yann

Lorena
Posts: 68
Joined: Mon Jun 04, 2012 7:33 pm

Re: Stimulations modification

Post by Lorena »

Thank you Yann, that was exactly what I had troubles with. I imagined the meaning of some of the settings, for others I was totally lost.

Indeed, the problem I had was that I needed to show alternating stimulus class 1/class 2, but using that box settings made the stimulus last on the screen for more than the time I had set for it. I thought this could be for the random appearance of the stimulus (sometimes class 1 should appear more time, for example, because it appeared 2 or 3 times in a row). So, I modified the Lua script deleting this part of the code and could solve my problem.

Thank you very much for your help, yor answers are always a guide for me to solve my problems.

Regards,

Lorena

Post Reply