Page 1 of 1

D2Box

Posted: 31 May 2006, 10:54
by luisgomes
Hello,

I'm configuring bci2000 for a mu-rhythm task, with AR analysis for feature extraction, and the D2Box task as feedback.

I'm using the D2Box because of its configuration flexibility, which allows me to program different (multi-dimensional) tasks.

I wanted to measure the system's performance given different parameters, in offline operation, so i coded a file "Playback" Source module, which takes a previous recorded session as input and "plays" it like it was live input.

My question is: can i configure the D2Box to place targets in a non-random (predefined) sequence? that way i could repeat the offline session..

thank you!

Combined signal processing ...

Posted: 01 Jun 2006, 11:05
by gschalk
Luis,

We have had the idea with the playback source come up many times over the past few years. To date, we have always rejected the possibility of writing a source like this ourselves, and have thus also not implemented the possibility for controlling modules from restored states (such as the targetcode states stored in the datafile). While it might be nice to do this, we have resisted this possibility for a number of reasons. The most important reason is that that implementation of this possibility facilitates simulations with small datasets and simple statical metrics (such as the change in hit rate due to a change in signal processing parameters), rather than the use of comprehensive offline analyses using more sophisticated statistical metrics (such as r^2 or p).

In, we do not currently have the capacity to place targets in a predefined sequence, and while possible to implement, I would discourage this possibility.

I hope this helps.

The Gerv

D2Box

Posted: 01 Jun 2006, 11:05
by mellinger
Luis,

there is no configuration option for replicating a task sequence.
As a simple modification, I suggest using a parameter for the random number generator seed, so information about the sequence will be preserved in that parameter.

In Application/D2Box/Task.cpp, TTask::Initialize(), there is a line reading

Code: Select all

randseed=-ctime;
Replace this by

Code: Select all

if(Parameter("TaskRandSeed")!=0)
  randseed=Parameter("TaskRandSeed");
else
  randseed=-ctime;
and add a definition for the new parameter to the constructor. In that definition, you should specify the parameter value to be zero -- that way, your modified D2Box task will behave as usual by default.

Regards,
Juergen