psychopy.org | Reference | Downloads | Github

Technical issues when running experiment on Pavlovia

URL of experiment: (The experiment is in running status and I still have credits. If I share the link, will this consume a credit?)

Description of the problem: I uploaded my experiment a couple of days ago to Pavlovia, after checking that it worked well on my laptop and other computers with different OS. After a couple of minutes of testing, I started receiving messages from participants (recruited via Prolific) reporting different errors. To give you some examples, two participants said they received the following error:
TypeError: Cannot read property ‘readPixels’ of undefined

Some participants said that their browser (Chrome) crashed, and one of them even said that the experiment made his computer crash :open_mouth:. At that point I decided to pause the study on Prolific.
I am trying to understand what is wrong with the study, and see if there’s a way of avoiding all these errors. The experiment is a bit long (5 mins) and has some videos. Maybe that might explain these technical issues? Also, is there a recommended “limit” on how many participants can take part in the study simultaneously?

If you share the URL of the experiment on gitlab.pavlovia.org (but not the run.pavlovia.org version) that will allow us to inspect it.

Possibilities that spring to mind are

  • a memory error where the machines are running out of memory (probably in the graphics card) while trying to load the movies. If that’s it then we’ll need to work out how/why that’s happening
  • a movie file with a different format, now supported by all browsers?

There isn’t a limit on the number of participants running and I’m confident that won’t be affecting you.

By the way, I noticed you had another post about the video not updating on each trial (sorry - I didn’t have any idea what might cause that and so hadn’t responded). Did you resolve that issue?

Hi @jon, thanks for your message. My gitlab experiment is here: https://gitlab.pavlovia.org/Mardock/box-movement (I changed the experiment status to Pilot mode now)

Regarding the videos, I still haven’t found a solution to my problem (i.e. how can I repeat a video on Pavlovia across trials, so that I don’t need to have multiple copies of the video for each trial?)

Edit: I just realized that other Psychopy users had similar problems a couple of months ago, here and here, and apparently the solution they found was to create multiple copies of the video files…

I think that the fact of having so many videos might be one of the main reasons why my experiment keeps crashing. Isn’t there a way (maybe with a code component) to repeat the video file on every trial?

By the way, my videos are all in .mp4 format.

Yes, repeating the video should be fine (i.e. I consider this a bug). We’ll need to work out why it’s failing (but most likely the situation is that the lib is detecting this is the same movie and “continuing” rather than “restarting” the video so we’ll need to add some explicit line to restart from beginning). I’ll get @apitiot to look into both the memory and restart issues

1 Like

Great! Thanks a lot @jon! Hopefully this will work :slightly_smiling_face:

Actually, I’ve just posted on your other issue, that Alain has already implemented the reset method for movies (but we weren’t using it in the output code) so you should be able to manually start the movies from the beginning on each trial using a Code Component, and in future we’ll make sure the Builder-generated code does this for you automatically

Great. Thanks @jon. In the meantime, and in case anyone else needs to implement the reset method, here’s my previous post and jon’s Code Component