In running online, just the first sound of many sounds is presented

Hi @sotiri, thank you so much for your help. I apologize for replying late. I was hardly trying to troubleshoot my experiment. I tried a visual task which is very similar (though not completely) to the auditory task I sent here and it worked well in pavlovia but I don’t know why the auditory doesn’t work! I did whatever changes I think I should do but still get a single sound and then I don’t get an error but it remains in a gray screen with nothing happening.
I defined new variables as “var” and also defined functions in js file in pavlovia.
I share the new version of my experiment here, as it contains new changes that were necessary.


And by the way, list[a][b][c] is referring to single elements in my big list called “total”. As these are unprepared numbers! for presentation, they need to be multiplied by 0.25 or 0.27 to give me the duration of the sound I want.
If you couldn’t access my new experiment in pavlovai, just let me know to make it public for your access.

Hi @Zhaleh, no problem, thanks for the extra info. Step by step I’m hoping we can have this figured out! Because the repository that my fork was based on has been removed, would it be possible to give me developer access to the one you link to above, so that I can pick up from where you left off? With reference to the screenshot attached, you can allow me into the project via member settings. Thanks, x

Hi @sotiri, I gave you access as developer to my project there. Hope we can solve it together. What is weird is that I have a visual task just like the auditory one. I mean their code is very similar but the visual task works well on my system!

Brilliant, many thanks, I’ll get on this first thing tomorrow, more soon, cheers, x

Hi @Zhaleh, apologies for the delay in my response. As it happens there is a bug in PsychoPy that is preventing the sound duration variable to take effect. I have fixed that in my fork below. Is the result closer to what you had in mind? Thanks again for flagging, x

Many many thanks for your effort in correcting my code. However the result is not exactly like what it is designed for (I mean some of them are correct and some are not!), but after this much effort in making it produce sounds, it’s really exciting that it at least produces sounds and reach the stage of asking the question!
If you run this psychopy code, you will see what we’re aiming to achieve. As you will hear, all sequences induce beat.
audioseqq.psyexp (19.5 KB)
But I’m interested to know what changes did you make to make it work.

Thanks for your patience @Zhaleh. I can only imagine the frustration of having everything working on the desktop to then discover the online version is having unexpected playback issues.

I created a separate repository for the latest .psyexp you sent over and have fixed the PsychoPy bug mentioned above along with a few other JS specific bits for which I had to turn off automatic translation in Coder.

In particular, I had to place certain functions in the global scope to make them available for the rest of the script. I also replaced the random module import in your JS with a Math.random() built-in based expression. Finally, a couple of shuffle() calls needed prefixing with util.

Please consult my fork for more details. Hope that helps, s.

Hi @sotiri, many thanks for your time and effort, I really appreciate it.

1 Like

Hi @sotiri . Could you please help me in this. My experiment has the same problem again!

Hi @Zhaleh, sorry the audio playback error? Are you running the latest PsychoPy? Could you send me a link to you repo? Thanks, s.

Hi @sotiri , thanks for your response. Unfortunately something happened to my laptop and I lost my data there. I don’t know if it’s because of that or not, but I cant run the experiment we worked on. Now I’ve created a project (the same project as before) with the name of audseq and I added you as a member to that. Could you please look at that?

Hi @Zhaleh, thanks for giving me access, no problem, let me take a look, x

Thanks @sotiri , When we were working on this a while ago, you created a repository called “audioseqq”. I’m not sure why it doesn’t work and I get the “404 not found” error. Do you know why this happens?

Hi @Zhaleh, sorry could you make it developer access? There are three repositories that we worked on before, I have transfered all of them to the support account:

Hi @ @sotiri , I gave you developer access. I’m sorry if I have a little difficulty in understanding these things. but all these three links you sent lead me to the same project in my pavlovia account by the name of “audioseqq” and I can’t run it! when I hit “pilot” i go to a page with 404 error.
How can I see what changes you made and make it work?

Hi @Zaleh, sorry Discourse will sometimes obscure Pavlovia links when not logged in. Do the ones below work maybe? You can still copy and paste the URL in your browser window if not I believe:

gitlab.pavlovia.org/support/audioseqq
gitlab.pavlovia.org/support/seq_auditory
gitlab.pavlovia.org/support/seq_audi

In any case, I have prepared a .psyexp fixing most of the bugs in your study. There may be a few leftover issues, but you would need to include the resources, conditions file and audio stimuli for me to properly address them please, x

audioseqq.psyexp (32.3 KB)

Hi @sotiri, Thank you very much for your files. Unfortunately they get 404 error and I can’t run them. And about the .psyexp file, I think we need to change “random.randint” to “randint” and “random.shuffle” to “shuffle” cause we’ve defined them in the code_js routine, otherwise it won’t work. and my experiment doesn’t have any resourcs, or audio stimuli and these things. It’s supposed to give us what we want by itself and in my computer it does, just online it encounter problems.