Hi, thank you for your reply!
I tried your suggestion and installed the glfw
backend (glfw
and pyglfw
on PIP). It does solve the issue with the GammaRamp, but it unfortunately leads to new problems:
First, the mouse can no longer be initialzed:
File "/home/usb/Dokumente/experiments/myexperiment.py", line 60, in <module>
mouse = event.Mouse()
File "/home/usb/miniconda3/lib/python2.7/site-packages/psychopy/event.py", line 578, in __init__
self.setVisible(visible)
File "/home/usb/miniconda3/lib/python2.7/site-packages/psychopy/event.py", line 772, in setVisible
w.set_mouse_visible(visible)
AttributeError: 'LP__GLFWwindow' object has no attribute 'set_mouse_visible'
Commenting out the mouse initialization temporarily for more debugging there is a new problem with text stimuli. Apparently, a pygame font is used but not found?
3.5219 ERROR Couldn't find font on the system. Using freesansbold.ttf instead! Font names should be written as concatenated names all in lower case.
e.g. 'arial', 'monotypecorsiva', 'rockwellextra', ...
Traceback (most recent call last):
File "/home/usb/Dokumente/experiments/myexperiment.py", line 70, in <module>
execfile("mylibrary.py")
File "mylibrary.py", line 13, in <module>
okText = visual.TextStim(win, text = 'OK', height = 120/2.71, color='black', pos=(.4*winwidth,-.4*winheight))
File "/home/usb/miniconda3/lib/python2.7/site-packages/psychopy/visual/text.py", line 159, in __init__
self.setHeight(height, log=False) # calls setFont() at some point
File "/home/usb/miniconda3/lib/python2.7/site-packages/psychopy/visual/text.py", line 207, in setHeight
setAttribute(self, 'height', height, log)
File "/home/usb/miniconda3/lib/python2.7/site-packages/psychopy/tools/attributetools.py", line 141, in setAttribute
setattr(self, attrib, value)
File "/home/usb/miniconda3/lib/python2.7/site-packages/psychopy/tools/attributetools.py", line 32, in __set__
newValue = self.func(obj, value)
File "/home/usb/miniconda3/lib/python2.7/site-packages/psychopy/visual/text.py", line 202, in height
self.setFont(self.font, log=False)
File "/home/usb/miniconda3/lib/python2.7/site-packages/psychopy/visual/text.py", line 270, in setFont
setAttribute(self, 'font', font, log)
File "/home/usb/miniconda3/lib/python2.7/site-packages/psychopy/tools/attributetools.py", line 141, in setAttribute
setattr(self, attrib, value)
File "/home/usb/miniconda3/lib/python2.7/site-packages/psychopy/tools/attributetools.py", line 32, in __set__
newValue = self.func(obj, value)
File "/home/usb/miniconda3/lib/python2.7/site-packages/psychopy/visual/text.py", line 262, in font
bold=self.bold)
File "/home/usb/miniconda3/lib/python2.7/site-packages/pygame/sysfont.py", line 320, in SysFont
return constructor(fontname, size, set_bold, set_italic)
File "/home/usb/miniconda3/lib/python2.7/site-packages/pygame/sysfont.py", line 243, in font_constructor
font = pygame.font.Font(fontpath, size)
pygame.error: font not initialized
I can imagine to install a missing font or to switch to a different one, but I have no clue how to deal with the mouse problem. Have you had anything like this before when using pyglfw
?