Stimulus Onset Time / GetSecs Issue on Linux

Hello,

I’ve noticed a peculiar error message for 3 out of ~50 participants in one of my studies. This is an fMRI study being run on a laptop. I’ve pasted the full command window output below:

PTB-INFO: This is Psychtoolbox-3 for GNU/Linux X11, under Matlab 64-Bit (Version 3.0.18 - Build date: Jun 27 2022).
PTB-INFO: OS support status: Linux 5.18.10-76051810-generic Supported.
PTB-INFO: Type 'PsychtoolboxVersion' for more detailed version information.
PTB-INFO: Most parts of the Psychtoolbox distribution are licensed to you under terms of the MIT License, with
PTB-INFO: some restrictions. See file 'License.txt' in the Psychtoolbox root folder for the exact licensing conditions.
PTB-INFO: For information about paid support, support memberships and other commercial services, please type
PTB-INFO: 'PsychPaidSupportAndServices'.
PTB-INFO: OpenGL-Renderer is AMD :: AMD RENOIR (DRM 3.46.0, 5.18.10-76051810-generic, LLVM 12.0.0) :: 4.6 (Compatibility Profile) Mesa 21.2.6
PTB-INFO: VBL startline = 1080 , VBL Endline = -1
PTB-INFO: Measured monitor refresh interval from VBLsync = 16.667604 ms [59.996624 Hz]. (50 valid samples taken, stddev=0.000674 ms.)
PTB-INFO: Reported monitor refresh interval from operating system = 16.667222 ms [59.998001 Hz].
PTB-INFO: Small deviations between reported values are normal and no reason to worry.
PTB-INFO: Using modified PortAudio V19.7.0-devel, revision 147dd722548358763a8b649b3e4b41dfffbcfbb6
Snd(): Initializing PsychPortAudio driver for sound output.
Snd(): PsychPortAudio will be blocked for use by your own code until you call Snd('Close');
Snd(): If you want to use PsychPortAudio and Snd in the same session, make sure to open your
Snd(): stimulation sound device via calls to, e.g., pahandle = PsychPortAudio('Open', ...);
Snd(): *before* the first call to Snd() or any function that might use Snd(), e.g., Beeper()
Snd(): or the Eyelink functions with auditory feedback. Call Snd('Open', pahandle) next, to
Snd(): share that pahandle audio device with Snd(), Beeper() et al. for optimal collaboration.
Snd(): Consider using PsychPortAudio('OpenSlave', ...); on a master device and pass that slave
Snd(): handle to Snd('Open', ...) if you want to allow Snd() to operate fully independently.
Snd(): You may want to read 'help Snd' about other points to consider wrt. pahandle sharing.
PTB-INFO: Using modified PortAudio V19.7.0-devel, revision 147dd722548358763a8b649b3e4b41dfffbcfbb6
PTB-INFO: Using modified PortAudio V19.7.0-devel, revision 147dd722548358763a8b649b3e4b41dfffbcfbb6
PTB-INFO: Using modified PortAudio V19.7.0-devel, revision 147dd722548358763a8b649b3e4b41dfffbcfbb6
PTB-INFO: Using modified PortAudio V19.7.0-devel, revision 147dd722548358763a8b649b3e4b41dfffbcfbb6
PTB-INFO: Using modified PortAudio V19.7.0-devel, revision 147dd722548358763a8b649b3e4b41dfffbcfbb6
PTB-INFO: Using modified PortAudio V19.7.0-devel, revision 147dd722548358763a8b649b3e4b41dfffbcfbb6
PTB-INFO: Using modified PortAudio V19.7.0-devel, revision 147dd722548358763a8b649b3e4b41dfffbcfbb6
PTB-INFO: Using modified PortAudio V19.7.0-devel, revision 147dd722548358763a8b649b3e4b41dfffbcfbb6
PTB-INFO: Using modified PortAudio V19.7.0-devel, revision 147dd722548358763a8b649b3e4b41dfffbcfbb6
PTB-INFO: Using modified PortAudio V19.7.0-devel, revision 147dd722548358763a8b649b3e4b41dfffbcfbb6
PTB-INFO: Using modified PortAudio V19.7.0-devel, revision 147dd722548358763a8b649b3e4b41dfffbcfbb6
PTB-INFO: Using modified PortAudio V19.7.0-devel, revision 147dd722548358763a8b649b3e4b41dfffbcfbb6
PTB-INFO: Using modified PortAudio V19.7.0-devel, revision 147dd722548358763a8b649b3e4b41dfffbcfbb6
PTB-INFO: Using modified PortAudio V19.7.0-devel, revision 147dd722548358763a8b649b3e4b41dfffbcfbb6
PTB-INFO: Using modified PortAudio V19.7.0-devel, revision 147dd722548358763a8b649b3e4b41dfffbcfbb6
PTB-INFO: Using modified PortAudio V19.7.0-devel, revision 147dd722548358763a8b649b3e4b41dfffbcfbb6
PTB-INFO: Using modified PortAudio V19.7.0-devel, revision 147dd722548358763a8b649b3e4b41dfffbcfbb6
 | None: No Response 
 | None: No Response 
 | Press 7&: Response Inaccurate 
 | Press 7&: Response Accurate 
 | Press 7&: Response Accurate 
 | Press 2@: Response Accurate 
 | Press 2@: Response Accurate 
 | Press 2@: Response Accurate 
 | Press 2@: Response Accurate 
 | Press 2@: Response Accurate 
 | None: No Response 
 | Press 7&: Response Accurate 
 | Press 2@: Response Accurate 
 | Press 7&: Response Accurate 
 | Press 7&: Response Accurate 
 | Press 2@: Response Accurate 
PTB-ERROR: OpenML timestamping reports that flip completed before it was scheduled [Scheduled no earlier than 1707739887.292816 secs, completed at 1707739884.800377 secs]!
PTB-ERROR: This could mean that sync of bufferswaps to vertical retrace is broken or some other driver bug! Check your system setup!
 | Press 2@: Response Accurate 
 | Press 7&: Response Accurate 
 | Press 7&: Response Accurate 
 | Press 7&: Response Accurate 
 | Press 2@: Response Accurate 
 | Press 7&: Response Accurate 
 | Press 7&: Response Accurate 
 | Press 7&: Response Accurate 
 | Press 7&: Response Accurate 
 | Press 2@: Response Accurate 
 | None: No Response 
 | Press 7&: Response Accurate 
 | Press 2@: Response Accurate 
 | Press 2@: Response Accurate 
 | Press 2@: Response Accurate 
 | Press 7&: Response Accurate 
 | Press 2@: Response Accurate 
 | Press 7&: Response Accurate 
 | Press 7&: Response Accurate 
 | Press 7&: Response Accurate 
 | Press 7&: Response Accurate 
 | Press 2@: Response Inaccurate 
 | Press 2@: Response Accurate 
 | Press 7&: Response Accurate 
 | Press 7&: Response Accurate 
 | Press 2@: Response Accurate 
 | Press 7&: Response Accurate 
 | Press 7&: Response Accurate 
 | Press 7&: Response Accurate 
 | Press 2@: Response Accurate 
 | Press 2@: Response Accurate 
 | Press 2@: Response Accurate 
ans =
   1.7077e+09
Total Time 446.07
[ Warning: Directory already exists.]  
[ > In <a href="matlab:matlab.internal.language.introspective.errorDocCallback('gradCPT_main_v4', '/home/salilab/Desktop/EyetrackCode/gradCPT_main_v4.m', 219)" style="font-weight:bold">gradCPT_main_v4</a> (<a href="matlab: opentoline('/home/salilab/Desktop/EyetrackCode/gradCPT_main_v4.m',219,0)">line 219</a>)]  
saving data- wait!Receiving data file 'S071R2.edf'
ReceiveFile status 10411493
Data file 'S071R2.edf' can be found in '/home/salilab/Desktop/EyetrackCode/data'
INFO: PTB's Screen('Flip', 10) command seems to have missed the requested stimulus presentation deadline
INFO: a total of 15 times out of a total of 8844 flips during this session.
INFO: This number is fairly accurate (and indicative of real timing problems in your own code or your system)
INFO: if you provided requested stimulus onset times with the 'when' argument of Screen('Flip', window [, when]);
INFO: If you called Screen('Flip', window); without the 'when' argument, this count is more of a ''mild'' indicator
INFO: of timing behaviour than a hard reliable measurement. Large numbers may indicate problems and should at least
INFO: deserve your closer attention. Cfe. 'help SyncTrouble', the FAQ section at www.psychtoolbox.org and the
INFO: examples in the PDF presentation in PsychDocumentation/Psychtoolbox3-Slides.pdf for more info and timing tips.

There are a few things that have me really stumped about this error. I am also collecting eye tracking data with an Eyelink and when this error happens, I notice that there is an extra long pause between the triggers of successive trials. Strangely, the onset times for my task in Matlab appear to go backwards in time and then jump ahead some. It seems like after this happens, all timing from GetSecs / KbQueueCheck is also impacted since these functions are still returning times that are consistent with the stimulus timestamps I’m getting. I expected them to be later than the onset times after the jump backward. Lastly, I can see when I look at the eye tracking data that the entire run takes about 2 seconds longer than normal, but the timing generated in the text above (using GetSecs) does not have the extra time added.

Is it possible that my system clock is behaving strangely and causing this issue? I’m happy to pay for support to get troubleshooting help. On runs where it doesn’t give the error message, is it safe to assume that everything is working normally?

Thanks in advance - I’m happy to share code / data files if that would be helpful. Unfortunately, I haven’t been able to figure out how to reproduce the problem reliably.

Anthony

Topic closed due to redundant post. See Inconsistent Clock Behavior on Laptop for continuation.