I’m using ‘glob.glob(os.path.join…’ to import some image stimuli, I’m then sorting these stims into a list and displaying them sequentially. My issue is, Psychopy seems to be displaying the images in a random order on every run; I cannot detect any pattern at all. I’m using Ubuntu 16.04, I’m not sure if this is the issue or not.
Here is the code:
#import stims stim_import = glob.glob(os.path.join('/home/jon/exp/stims/stims','*.png')) set_one = [visual.ImageStim(win, img, name='set_one-' + img) for img in stim_import[:8]] set_two = [visual.ImageStim(win, img, name='set_two-' + img) for img in stim_import[8:15]] purp = [set_one, set_one, set_one, set_one, set_one, set_one, set_one, set_one] for i in purp: i.draw() win.flip() core.wait(2) win.close() core.quit()
I want the images to import in a particular order, does anyone know how Psychopy selects stimuli from a directory to import? how does it select which image to import first, and why would this change every time this process occurs?