Howdy, Stranger!

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

Supported by

Sound files definition

I am building an experiment in which I would like to display simultaneous onset of sound files with two orthographic representations (one on the left and one on the right of the screen). Participants, based on what they heard, they have to choose via a button box one of the options to match the sound with the correct option. For this experiment I am struggling in the following:

  1. How to make the task forced-choice?
  2. On the table of the block loop I cannot find a way to define under my conditions the sound files (I have 2 experimental and 2 contol conditions)
  3. Is it possible to measure response times from the onset of the stimuli until the choice?

Thanks in advance for any advice.

Comments

  • Hi Aris,

    All of your questions are covered in the beginner's tutorial. How about to work through it and try to apply the info to your experiment?

    Eduard

    Buy Me A Coffee

  • Hi!

    I have watched the tutorial that you recommended several times, but still I have some issues in the aforementioned experiment. Here I attach a screenshot that may help understanding my problems with the task.

    1. I think I have defined in the block loop the orthographic choices that will be presented simultaneous in the sketchpad but for some reason I get the message that you can see in the screenshot.
    2. the button box I use is with two buttons and it also does not work although I think I have linked it with my variables (left choice button can be linked as 1 in the table loop while right choice button can linked as 2 in the table loop) .

    I want to measure response times and judgments. Any advice on these problems?

    Thanks in advance!

  • Hi Aris,

    there is no error in your screenshots (the blue banners are expected). I think what happens is that you use Opensesame 4 (the latest release), but follow a tutorial based on Opensesame 3. Perhaps don't watch the video, but check out the written part: https://osdoc.cogsci.nl/4.0/tutorials/beginner/

    Without more information on implementation I can't help more.

    Eduard

    Buy Me A Coffee

  • Hi Eduard,

    I have read the tutorial several times, there is no difference in the outcome. In my experiment--see 3rd pdf above, table loop--I will play sound files (these determine the conditions) and ppts have to choose via a button box (I want forced choice), choice 1 or choice 2. Correct response is assigned on the table based on the choices, 1 or 2 respectively.

    1. the button box is not working--its an RSP12--with two buttons (left and right that will correspond in the choices 1 and 2 respectively). The experiment freezes--this is not the case if I simply run it with the keyboard buttons.
    2. Another problem, if i use the keyboard response function, when I open the saved data after implementation, the correct response is not there (there is only 0 in that part of the table)
    3. Without the coroutines function the orthographic choices do not appear on the screen, only the sound, but I have the feeling that if I use coroutines function, it somehow only displays the stimuli but the keyboard responses do not work.

    Thank you for your time!

  • Please share your experiment (the one with the keyboard_response). I don't know why the button box doesnt work, but that we can leave for later.

    Eduard

    Buy Me A Coffee

  • Hi Aris,

    In the loop table you define correct response as either 1 or 2. However, in the keboard response item you only allow z and m as response keys. Therefore, all responses are incorrect. Either change what the correct responses could be, or allow different response keys.

    Also your co-routines is incorrect, you cannot have all the items in the co-routine start at the same time. Especially not if there are multiple sketchpads (you can't present two screens on one screen at the same time). Actually I don't think you need a co-routine. If you first present your sound with a duration of 0 .

    It will continue in the sequence with the next item (your stimuli), which you also set to 0 . Next will be the keyboard response item. Like that you sound and visual stimulus will appear at essentially the same time, and the response time measured from onset of stimulus.

    Does this make sense? Of course, you can simply try it, and see whether it suits your need.

    Eduard

    btw. integrating a response box is probably easier outside a co-routine that inside. (not sure that your issues are because of that though)

    Buy Me A Coffee

  • Hi Eduard!

    Thank you for the help, it seems to work like that! The unresolved issue is still the button box --I have removed the coroutines function, I also tried to define in the table loop as correct values, 1,2 and then same in the response box as allowed responses but it freezes again. (Without the the button box the experiment works perfectly now but i need it)

    What could I try? (I have a mac, don't know if that is a problem--i am using a type c usb to incorporate the button box which is in usb)

    Thank you once again.

  • Hi Aris,

    Try to find out how to interact with that button box with Python (at the vendor, or on google). If there is an explanation for that, you can make it work with the inline-script item.

    Eduard

    Buy Me A Coffee

  • I have used this inline-script item but still--found it in your website.

    t0 = clock.time()

    srbox.start()

    button, t1 = srbox.get_button_press(allowed_buttons=[1,2],

    require_state_change=True)

    if button == 1:

    response_time = t1 - t0

    print('Button 1 was pressed in %d ms!' % response_time)

    srbox.stop()

  • Please provide error messages and more context, where is this code (where in the experimental sequence, which phase).

    Eduard

    Buy Me A Coffee

  • There is no error or any message, the experiment just freezes--it starts and after the instructions it stucks, it doesnt proceed to the experiment. Compared to the keyboard experiment above which works, the only changes I have made are to define as correct responses 1,2 on the table loop, incorporate the inline script and the response button box that I have also set as correct responses 1;2.

  • I can't test it myself, because I don't have a response box, what you can try is following:

    • move the new_1_srbox item to before all the loops (early in the experiment)
    • rename it to srbox
    • replace the autodetect to the actual portnumber (you might need to try a few to find out which one is the correct one, see here)


    Buy Me A Coffee

  • Hi Eduard! Thank you once again. I changed the name, moved it before the first loop (practise phase), tried the names (COM4, /dev//tty0) and the inline python script you provide exactly below the responsebox--and above as well), but the experiment freezes again.

    t0 = clock.time()

    srbox.start()

    button, t1 = srbox.get_button_press(allowed_buttons=[1,2],

        require_state_change=True)

    if button == 1:

        response_time = t1 - t0

        print('Button 1 was pressed in %d ms!' % response_time)

    srbox.stop()


    I had mentioned to you that I have a mac, could that be a compatibility problem? --I have allowed the access and all these stuff.

  • Perhaps, with these types of things it is hard to help you, because I have neither a device to try it out, nor the same os as you do.

    To find out whether the connection with the device is made, you can try to set the timeout to some other value than none . If if still freezes you know the connection is the problem.


    tried the names (COM4, /dev//tty0)

    Not sure, but these were just suggestion in the documentation. If you have other possible port names you can try those. Essentially, this is a connection to the serial port of your pc (I believe), so you can maybe google how to access the serial port (e.g. with Python) and see whether you can detect the device like that. That might help with getting sufficient info to also make it work in Opensesame.

    Finally, you can of course try to contact the manufacturer and ask them how you can detect your device on your computer. Some extent of user support can be expected from them.

    Other than that there is not much that we can do unfortunately.

    Eduard

    Buy Me A Coffee

  • I tried the timeout other than none and it still freezes. I also searched for the name of the button box in the system of my laptop, tried that as well as a name but i get an error that it is unknown. I really don't understand. Could that be any definition thing on the table loop? Besides that I have set up correct responses 1;2.

  • Hi,

    I don't know. You can try plain python to detect the port number. For example these instructions might work: https://www.socsci.ru.nl/wilberth/python/srbox.html

    Could that be any definition thing on the table loop? Besides that I have set up correct responses 1;2

    quite unlikely, but I don't want to exclude this possibility.

    In any case, I don't think I can help you more with this. As I said, neither do I have such a device, nor a Mac, so all I can do is google and guess. Sorry.

    Perhaps someone else has something to contribute?

    Eduard

    Buy Me A Coffee

  • sorry I tried it but i am getting syntax errors--didnt change anything.

    Is there anything specifically from the script that I can use in the inline script of OpenSesame?

    And btw its not a mac problem at the end, I also tried it in windows, there the experiment reaches the first item and then the button box does not work to proceed. Somehow OS does not recognise it, please tell me what can I do with this, coz I cannot find any solution.

  • Hi!

    I have managed to solve the problem just by changing the button box and instead of using the srbox function I am using the keyboard responses. The experiment was working perfectly and without any change, I am now getting this message:

    "The experiment process seems to have died as the result of an unknown problem. This should not happen!

    This error occurred in the unknown phase of item unknown.

    An ExperimentProcessDied is raised when the experiment process died. This is generally the result of a bug in one of the underlying libraries that causes Python to crash. This should not happen! If you experinence this error often, please report it on the support forum."

    Can you help with this? I dont get it how it suddenly stopped working

  • I have managed to solve the problem just by changing the button box and instead of using the srbox function I am using the keyboard responses.

    Nice to hear!

    The experiment was working perfectly and without any change, I am now getting this message:

    Is this this consistent or occurs only occasionally? At which stage does it crash? Can you share the experiment?

    Eduard

    Buy Me A Coffee

  • Hi! Thanks for the replies. At some point it was occasionally but now it's consistent. It crashes in the either in the 2nd or 3rd item during the practice phase.


    The strange thing is that I tried it in another laptop (windows) and it works. But I have to run it in mine (mac), so I am wondering how can I solve this issue.

  • The website does not let me upload. It says "request failed status code 413"

  • upload it elsewhere and share the link here. e.g. wetransfer

    Buy Me A Coffee

  • Hi,

    I can't see anything obviously wrong with it. That being said it also crashes on my system with some errors related to the audio (below my tracestack for completeness sake). Not sure whether this is it, but the problems disappear after I deleted the koci.wav recording (and the correspoding entries in the loop table). So maybe the file is corrupt?

    Other than that, I have no clue what could cause the problems.

    Eduard

    Buy Me A Coffee

  • I just believe that this version of OpenSesame is not compatible with mac 'cause these issues do not appear on windows--I have confirmed this with another 4 computers and again it works on windows and not in mac. This would be good to be stated for the mac users in the website 'cause it causes too much frustration with no reason. Thank you anyway!

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