Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Supported by

Can't adjust sampler duration on osweb

Hi, I've been using a long auditory file and wish to use just the first second of the file for an auditory perception task. I've set both duration and "stop after" to the duration I want and it plays perfectly running on PC. However, when I run it on osweb it plays the full duration and overlap with later auditory cues. How can I change it? Thank you so much

Comments

  • Hi Lily,

    Some of the sampler controls (panning, pitch, stop after, and fade in) are indeed not supported in OSWeb. I added this to the documentation, and at some point we will implement this functionality in OSWeb.

    For now, an easy workaround might be to create a copy of your sound file that contains only the first second of the sound. Does that work for you?

    Cheers!

    Sebastiaan

    Buy Me A Coffee

  • Dear Sebastiaan,

    Thank you so much for the quick reply. Changing file durations might be difficult for my task as I'm testing the perception of many different durations of the same tone. Although making a collection of blocks of the different durations and then randomize it under the main sequence should theoretically work? Is it possible to export the experiment as python or java code by any chance?

    Jatos and OSWeb runs fabulously for the rest of my experiment though, thank you for setting up this fantastic tool!

    Best,

    Lily

  • Although making a collection of blocks of the different durations and then randomize it under the main sequence should theoretically work?

    Exactly. And if the sounds have filenames that indicate their duration, then you can use a variable in the sampler to select the appropriate sound file, e.g. my_sound_[duration].ogg .

    Is it possible to export the experiment as python or java code by any chance?

    That's not how OpenSesame works. Instead, a runtime (written either in JavaScript for OSWeb or in Python for the desktop) is necessary to run the experiment. If you export your experiment to JATOS, this runtime is bundled along with the experiment.

    Cheers!

    Sebastiaan

    Buy Me A Coffee

  • Amazing it worked! Thank you so much for your help!

    Another minor issue, I've made the key response so that I only need to press the response key once when doing the task on the computer (start=key press; end=key release), but on OSweb I will need to press the response key twice. Is there any way of changing it?

    Many thanks!

    Lily

  • Hi Lily,

    I'm guessing you made use of the keyrelease event type in the keyboard_response , which is not supported by OSWeb. Is it really necessary to wait for a key release? In many cases, the press is what you're interested in, so in that case you can simply remove the key-release response.

    Cheers,

    Sebastiaan

    Buy Me A Coffee

  • Thanks Sebastiaan, it worked prefectly!

    One more (hopefully last) question, I've been testing my experiment on various browsers and it to work on chrome, firefox, microsoft edge, and not safari or internet explorer. Does this sound correct? Is there a browser compatibility page that you might be able to point me towards?

    Many thanks and keep well,

    Lily

  • Hi Lily,

    The following browsers should be supported:

    So both Safari and Internet Explorer should work. Could you post the error message from the Safari error console?

    Cheers!

    Sebastiaan

    Buy Me A Coffee

  • Hi Sebastiaan,

    When I open the link on IE, there is no error message and just a blank screen

    For Safari, there is also no error message. I am able to see the welcome screen but cannot hear any audio file and the screen stays blank afterwards. Not sure why it's doing that. I have .wav files and one .jpg file. Here's the link in case it might be helpful:

    https://experiments.jatos.org/publix/116/start?batchId=121&personalMultipleWorkerId=445 

    Thanks so much!

    Lily

  • @Daniel Could you give this experiment a spin on Safari?

    Buy Me A Coffee

  • edited June 23

    @sebastiaan & @Lily . I did, and I can confirm the sound is not working. All else seems to work quite well, as in, I don't see any blank screens without any progress. I do get some weird output in the console:

    Mainly the 403 (Forbidden) error for the OpenSesame logo is weird. This is issued by the server, which doesn't allow the download of the logo at its location, but this should then be the case for any browser and not just safari. I do notice that it also takes a long while for the logo to load in other browsers, so it may be a latency issue.

    Playback of sound is forbidden by the browser, so we must be bumping into some weird Safari-specific browser security policies here that I don't know about.

    Internet Explorer support is also hit and miss I guess. With advanced things like playing sound or other kinds of media, the chances are that Internet Explorer is simply too old. The support Sebastiaan referred to is mainly the javascript syntax, meaning that Internet Explorer should be able to parse the Javascript code osweb is written in. For other things like playing sound, or more specifically certain file types, it is harder to tell if it will work.

    In general I would advise to avoid Internet Explorer altogether because its timing characteristics are not that great either, and its browser share is minimal (< 2%) nowadays.

    Buy Me A Coffee

  • See also https://stackoverflow.com/questions/53059288/safari-browser-audio-play-is-not-working. Have you tried different audio file formats? It may be that you are using a format that is not supported by Safari.

    Buy Me A Coffee

  • Hi Daniel,

    Thanks for running it through. I've changed the file format to .ogg and still can't run it on Safari. Is there any other format that I should try out?

    Thanks!

  • Hi Lily.

    I sadly have no clue then and will need to investigate this further, but I don't have the time to do this now. I think this is a deeper lying problem that is related to the security models that are currently implemented by Safari. I tested this with one of our experiments which we use to test sounds (Capybara) that used to work perfectly, but now I get a different albeit related error message in the console:

    Unhandled Promise Rejection: NotAllowedError: The request is not allowed by the user agent or the platform in the current context, possibly because the user denied permission.

    So somehow, Osweb does not appear to receive permission anymore from the browser to play sounds...

    Buy Me A Coffee

  • edited August 6

    It is indeed a problem many a struggling with:

    I suggest advising users to steer clear from using Safari for experiments for now (which is recommendable anyway)

    Buy Me A Coffee

  • Hi Daniel,

    Yes I think that would be the best thing to do then. Thank you so much for helping trouble shoot!

    Take care,

    Lily

Sign In or Register to comment.

agen judi bola , sportbook, casino, togel, number game, singapore, tangkas, basket, slot, poker, dominoqq, agen bola. Semua permainan bisa dimainkan hanya dengan 1 ID. minimal deposit 50.000 ,- bonus cashback hingga 10% , diskon togel hingga 66% bisa bermain di android dan IOS kapanpun dan dimana pun. poker , bandarq , aduq, domino qq , dominobet. Semua permainan bisa dimainkan hanya dengan 1 ID. minimal deposit 10.000 ,- bonus turnover 0.5% dan bonus referral 20%. Bonus - bonus yang dihadirkan bisa terbilang cukup tinggi dan memuaskan, anda hanya perlu memasang pada situs yang memberikan bursa pasaran terbaik yaitu http://45.77.173.118/ Bola168. Situs penyedia segala jenis permainan poker online kini semakin banyak ditemukan di Internet, salah satunya TahunQQ merupakan situs Agen Judi Domino66 Dan BandarQ Terpercaya yang mampu memberikan banyak provit bagi bettornya. Permainan Yang Di Sediakan Dewi365 Juga sangat banyak Dan menarik dan Peluang untuk memenangkan Taruhan Judi online ini juga sangat mudah . Mainkan Segera Taruhan Sportbook anda bersama Agen Judi Bola Bersama Dewi365 Kemenangan Anda Berapa pun akan Terbayarkan. Tersedia 9 macam permainan seru yang bisa kamu mainkan hanya di dalam 1 ID saja. Permainan seru yang tersedia seperti Poker, Domino QQ Dan juga BandarQ Online. Semuanya tersedia lengkap hanya di ABGQQ. Situs ABGQQ sangat mudah dimenangkan, kamu juga akan mendapatkan mega bonus dan setiap pemain berhak mendapatkan cashback mingguan. ABGQQ juga telah diakui sebagai Bandar Domino Online yang menjamin sistem FAIR PLAY disetiap permainan yang bisa dimainkan dengan deposit minimal hanya Rp.25.000. DEWI365 adalah Bandar Judi Bola Terpercaya & resmi dan terpercaya di indonesia. Situs judi bola ini menyediakan fasilitas bagi anda untuk dapat bermain memainkan permainan judi bola. Didalam situs ini memiliki berbagai permainan taruhan bola terlengkap seperti Sbobet, yang membuat DEWI365 menjadi situs judi bola terbaik dan terpercaya di Indonesia. Tentunya sebagai situs yang bertugas sebagai Bandar Poker Online pastinya akan berusaha untuk menjaga semua informasi dan keamanan yang terdapat di POKERQQ13. Kotakqq adalah situs Judi Poker Online Terpercayayang menyediakan 9 jenis permainan sakong online, dominoqq, domino99, bandarq, bandar ceme, aduq, poker online, bandar poker, balak66, perang baccarat, dan capsa susun. Dengan minimal deposit withdraw 15.000 Anda sudah bisa memainkan semua permaina pkv games di situs kami. Jackpot besar,Win rate tinggi, Fair play, PKV Games