Howdy, Stranger!

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

Supported by

[solved] Crashing after one trial when recording audio

edited January 2013 in OpenSesame

Hello,

I've been running into a recurrent error when I try to run an experiment that involves recording audio. Essentially, everything works perfectly for the first trial, but rather than going on to the second trial, the program exits and then crashes.

I've included two screenshots below (clickable thumbnails). The first is of the interface when everything is normal. (This also shows the design of the experiment.) The second screenshot shows what happens after the program exits the one perfect trial, but before it crashes. I do not get error messages when the experiment exits, so I include the "post-error" screenshop in the hopes that the funny way my entire project design disappears from the overview pane might be diagnostic in some way.

The audio is recorded using the in-line script from here: http://forum.cogsci.nl/index.php?p=/discussion/107/solved-recording-speech-response/p1

I changed a few lines to specify the name of my file and the recording location, but I doubt that they are the problem, because the resulting wave file is correctly labeled and stored in the correct location for the first trial. The relevant lines are here:


import os os.chdir("C:/Users/Clara Cohen/Documents/Dropbox/D/ENproduction/testExperiment")

...


CONDITION=self.get('Condition')
LIST=str(self.get('List'))+""
SENTNUM=str(self.get('SentNum'))+"
"
SUBJECT=str(self.get('subject_nr'))+"_"
POSITION=str(self.get('count_Record_audio')+1)
WAVE_OUTPUT_FILENAME = CONDITION+LIST+SENTNUM+SUBJECT+POSITION+".wav"

However, something about the audio recording script item is responsible, because the experiment runs fine when I take it out.

After the error, when I close the program, I get the following error message:
"The logfile 'C:\Program Files\OpenSesame\opensesame.exe.log' could not be opened:
[Errno 13] Permissoin denied: 'C:\Program Files\OpenSesame\opensesame.exe.log' "

Please let me know if there is any other information you need to help me figure out why the program keeps crashing after the first trial.

Thanks,
Clara

Pre-error:

image

Post-error:

image

Comments

  • edited January 2013

    Hi Clara,

    Thanks for taking the time to describe your problem in sufficient detail. I think there are two things here.

    First, if an error occurs that is not caught by OpenSesame (which in general should not happen), it is written to the file opensesame.exe.log. (When running the Windows binary, that is. Under Linux, for example, the same error would appear in the terminal.) Apparently, you do not have write access to the OpenSesame folder, so the error log cannot be created. This is not really a problem, although obviously it's very inconvenient for debugging.

    But the real source of your trouble is probably this line:

    os.chdir("C:/Users/Clara Cohen/Documents/Dropbox/D/ENproduction/testExperiment")

    OpenSesame (under Windows, again) requires that the working directory is the OpenSesame folder, in order to locate its modules. If you change the working directory, OpenSesame will not be able to find itself anymore, and things will go horribly wrong. The solution will be to not use os.chdir, but to specify the full path for the output filename:

    WAVE_OUTPUT_FILENAME = "C:/Users/Clara Cohen/Documents/Dropbox/D/ENproduction/testExperiment/"+CONDITION+LIST+SENTNUM+SUBJECT+POSITION+".wav"

    Good luck and cheers,
    Sebastiaan

    Edit: Issue filed

  • edited 12:47PM

    Thank you very much for this response. I still got an error when I tried to run it:

    "IOError: [Errno Input overflowed] -9981"

    But I think this is unrelated to the script. In case anyone wants to know what ended up working, I gave up using the parallel feature to display the stimulus and record the response at the same time, because I realize that the stimulus display doesn't disappear when the audio recording follows it. (Yes, yes, but I'm new at this!) So I just have a stimulus display for 2 ms, followed by the audio recording script (while the stimulus is still visible on the screen), and everything works perfectly!

    Thank you so much for your help, Sebastiaan.

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