psychopy.org | Reference | Downloads | Github

Updating Every Frame Causing Memory Issues and Errors

URL of experiment: https://run.pavlovia.org/lanelewis406/kalman-task/html

Description of the problem:

Hi all,
I recently tried placing the experiment I have been working on online. However, I ran into an issue where the experiment wouldn’t update beyond the first frame on safari. I switched browsers to chrome to see if that would fix the issue. On chrome, the experiment updates frames but is super laggy and uses significant amounts of memory (this is the same across the several different computers I tried it on). I have several different visualizations and variables that need to update every frame to track the mouse and several conditions about the subject. My assumption is that this is causing the issue? In addition, after the condition is reached in the experiment to move onto the next routine (placing a green dot over a blue dot), the experiment crashes saying that a variable doesn’t exist that works perfectly fine in the not online version. My guess is that these issues are connected and maybe the frames updating weirdly is messing with the program and causing it to look for variables which might not exist yet? That being said, it seems very strange and I am at a loss on how to fix it. Any help on how to deal with it would be much appreciated! I am using psychopy 2020.1.3.
Thanks,
Lane

To reduce memory load you need to make sure that you only update positions etc. if they have actually changed.

You also need to define variables in Begin Experiment code blocks

Please search the forum for a link to my crib sheet for more Pavlovia tips.