Start time of image based on conditon file

If this template helps then use it. If not then just delete and start from scratch.

OS (e.g. Win10): win 10
PsychoPy version (e.g. 1.84.x): 2021.1.2
Standard Standalone? (y/n) If not then what?: y
What are you trying to achieve?:
I am trying to get an image to appear over a video at different time points based on a condition file. The videos cycle through randomly based on a conditions file. There is then an image with the header polygon and i have then put in start_time as another header.
What did you try to make it work?:
I have tried putting $start_time in the start box but to no success when set as both seconds and condition.

What specifically went wrong when you tried that?:
This is the error message I am receiving, I will an example of one of the condition file below but the whole experiment has quite a lot of video files so I won’t be able to upload all of them.

Questions\second", line 535
if image.status == NOT_STARTED and asarray($start_time):
Include pasted full error message if possible. “That didn’t work” is not enough information.

counting.xlsx (10.1 KB)

Many thanks,


Please provide the complete text of the error message.

Sorry didn’t mean to have it cut off!

## Running: C:\Users\James\OneDrive\Documents\Dissertation Exp without Questions\second ##
7201.1391     INFO     Loaded monitor calibration from ['2021_01_20 17:13']
  File "C:\Users\James\OneDrive\Documents\Dissertation Exp without Questions\second", line 535
    if image.status == NOT_STARTED and tThisFlip >= asarray($start_time)-frameTolerance:
SyntaxError: invalid syntax
##### Experiment ended. #####

Start and stop times are already treated as code so you don’t need a dollar sign

1 Like