Online experiment has no access to np

URL of experiment: space [PsychoPy] (pavlovia.org)

Description of the problem: It’s my first time trying to run an experiment online on Pavlovia. I get the attached error, which I think is about not having access to numpy which I have imported as np. I have imported all necessary modules at the beginning of the experiment. Should I do something else to make them accessible?

Hi Zahra, for online experiments, your builder experiment is compiled to PsychoJS (javascript). PsychoPy modules do not work there. You will have to find js alternatives for what you do with np functions.

1 Like

Hello

If you are using the PsychoPyßBuilder, it will import all libraries that have online counterparts. Importing python-libraries does work for online-experiments. Note that not all functionality might be offered. See the crib sheet for functions that need manual translation.

Best wishes Jens

2 Likes