Using MovieStim3 for a video rating task crashes with: "[Errno 24] Too many open files"

Hi all,

Can anyone help with the error message below? I suspect that MovieStim3 doesn’t close the files properly? What could be done to close the files after displaying them and hence (hopefully) avoid this error (and crash)?

OS (e.g. Win10): Windows XP (but crash also occurs on MacOS High Sierra, though without producing an error message - on the Mac PsychoPy simply freezes)

PsychoPy version (e.g. 1.84.x): 1.90.2

Standard Standalone? (y/n) If not then what?: Standalone versions as provided on the web site for both, Win XP and MacOS High Sierra

What are you trying to achieve?: I’ve set up a task using builder where participants have to rate videos (n = 300) on a Likert scale. Roughly halfway through the task PsychoPy crashes and produces the error message given below.

What did you try to make it work?: I’ve tried setting up a minimal working example containing just one routine that is repeated 300 times, playing the clip and then displaying a scale. Even in this simplistic scenario PsychoPy crashes halfway through.

What specifically went wrong when you tried that?: Complete error message:

Running: D:\Lab_pc_9_trajan\video_ratings\rate_videos.py

4.6403 WARNING Monitor specification not found. Creating a temporary one…
16.3675 WARNING User requested fullscreen with size [1024 768], but screen is actually [1680, 1050]. Using actual size
17.7338 ERROR Error in framebuffer activation
17.7338 WARNING Framebuffer object (FBO) not supported on this graphics card
Traceback (most recent call last):
File “D:\Lab_pc_9_trajan\video_ratings\rate_videos.py”, line 1086, in
File “C:\Program Files\PsychoPy2\lib\site-packages\psychopy\visual\movie3.py”, line 134, in init
File “C:\Program Files\PsychoPy2\lib\site-packages\psychopy\visual\movie3.py”, line 180, in loadMovie
File “C:\Program Files\PsychoPy2\lib\site-packages\moviepy\video\io\VideoFileClip.py”, line 81, in init
File “C:\Program Files\PsychoPy2\lib\site-packages\moviepy\video\io\ffmpeg_reader.py”, line 32, in init
File “C:\Program Files\PsychoPy2\lib\site-packages\moviepy\video\io\ffmpeg_reader.py”, line 256, in ffmpeg_parse_infos
File “C:\Program Files\PsychoPy2\lib\subprocess.py”, line 745, in init
OSError: [Errno 24] Too many open files
Error in atexit._run_exitfuncs:
Traceback (most recent call last):
File “C:\Program Files\PsychoPy2\lib\atexit.py”, line 24, in _run_exitfuncs
File “C:\Program Files\PsychoPy2\lib\site-packages\psychopy\data\experiment.py”, line 366, in close
File “C:\Program Files\PsychoPy2\lib\site-packages\psychopy\data\experiment.py”, line 351, in saveAsPickle
File “C:\Program Files\PsychoPy2\lib\site-packages\psychopy\tools\filetools.py”, line 149, in openOutputFile
File “C:\Program Files\PsychoPy2\lib\codecs.py”, line 896, in open
IOError: [Errno 24] Too many open files: u’D:\Lab_pc_9_trajan\video_ratings\data/test_rate_videos_2018_Sep_28_1556.psydat’
Error in sys.exitfunc:
Traceback (most recent call last):
File “C:\Program Files\PsychoPy2\lib\atexit.py”, line 24, in _run_exitfuncs
func(*targs, **kargs)
File “C:\Program Files\PsychoPy2\lib\site-packages\psychopy\data\experiment.py”, line 366, in close
self.saveAsPickle(self.dataFileName)
File “C:\Program Files\PsychoPy2\lib\site-packages\psychopy\data\experiment.py”, line 351, in saveAsPickle
fileCollisionMethod=fileCollisionMethod) as f:
File “C:\Program Files\PsychoPy2\lib\site-packages\psychopy\tools\filetools.py”, line 149, in openOutputFile
f = codecs.open(fileName, mode=mode, encoding=encoding)
File “C:\Program Files\PsychoPy2\lib\codecs.py”, line 896, in open
file = builtin.open(filename, mode, buffering)
IOError: [Errno 24] Too many open files: u’D:\Lab_pc_9_trajan\video_ratings\data/test_rate_videos_2018_Sep_28_1556.psydat’