smathot/OpenSesame — Issue #53: Conditional display ("Run if...") is very slow
Author: trombonechamp
Created: 2011-10-09 19:55:19+00:00
State: open

To reproduce:
1. Create a simple experiment with a simple series of timed trials. Set each one to take 700 ms or so.
2. Add many trials to the loop (say 100 or so)
3. Run the experiment and find the average time spent on each trial. It should be approximately equal to what you specified in step 1.
4. Add six or seven slides, text inputs, etc. Change all their "Run if..." values to something impossible (say, "[correct] = 10")
5. Repeat step 3. This should add about 40-50 ms to the trial. (In one extreme case with 16 conditional display expressions, the trials were slowed down by about 100 ms.)

In comparison with python scripts (which seem to run relatively quickly), this is very time consuming. Granted, this isn't the most precise measurement form in the world, but it gives a good rough estimate of how slow this is. I'm running GNU/Linux, and top indicates very low cpu usage.

Not only is this a problem on its own, but I am currently building an experiment that requires the user to be able to press a particular key at any point in the experiment, and to have that key press be recorded. Through some hacks I have made this work with OpenSesame, but it seems there is no way to record that key press if it is pressed during this latency period.