Creating a new experiment
Making Datasource, moving stimuli over, and making the experiment.
Last updated
Making Datasource, moving stimuli over, and making the experiment.
Last updated
First, you will move the appropriate image and audio files for the unique items for the subject into the right opus folders: (here is a sample such file, for 11_08, [[11_08_stimuli.xlsx]])
Start with the stimuli spreadsheet found in the in-lab folder in the subject files on opus, e.g. opus/SubjectFiles/08_10/In-lab/stimuli/08_10_stimuli.xlsx
move images open the images folder on bergelson2014-01/Users/ebergelson/Desktop/seedlings_stimuli/images_greybackground_960x960_150dpi a. make sure it's THAT folder and not the 'raw' images folder a. select the images indicated in the spreadsheet in column b, just items #9-16 and copy and paste them into the right subject folder, e.b. 08_10/in-lab/stimuli/Image_Stims a. you must check column e, to see if it's a duplicate image and thus has a number after the word name, e.g. ball3, do not put 'ball' into the subjects' folder, only put ball3.jpg in the images folder
move audio open the audio folder /Users/ebergelson/Desktop/seedlings_stimuli/audio_stimuli_stereo_rightsilent_72db a. make sure it's THAT folder and not any of the other audio folders b. select the audio files indicated in the spreadsheet, with the carrier indicated in column, e.g. if it's banana and can, find can_banana.wav, and move them into, e.g. 08_10/in-lab/stimuli/Audio_Stims
Make sure there are 8 files in your image_stims folder and 8 files in your audio_stims folder
Occasionally you'll need to move a new mono sound file or warmup image file over for the warm-up trials, they will then have a blue fill on the spreadsheet and a note indicating this
Select the appropriate section of this [[attachment:datasource_template_with_formulas.xlsx]] for the order you are trying to generate (1-4)
Make sure the process_stimuli.py script is in the Github folder (Desktop/Github/SeedlingsBabylab/stimuli_datasource) on the machine you're using, and the xlrd is downloaded onto the computer a. update the stimuli.xlsx file with the words for testing
Check/change the directory: For Mac: Open a terminal window (e.g. by typing 'terminal' in the spotlight) For PC: type 'cmd' in the Search bar a. You need to tell the terminal to be in the directory where your script file lives: the Desktop/Github/SeedlingsBabylab/stimuli_datasource a. Check the working directory by typing 'pwd' [print working directory] and the pressing return. That will tell you where the terminal window is expecting files to be. a. Change the working directory to the proper place by typing 'cd' [change directory] and then the path to the scripts folder, e.g. cd /Users/elika/Desktop/Github... (now if you enter pwd and hit return it should say the right directory) a. Enter the following command: "python process_stimuli.py datasource_template_with_formulas.xlsx stimuli.xlsx output.csv" to launch the file.
(needs to be fixed more later)
Connect to internet by plugging in the green cable into the ethernet port on the back of the computer to the left of where the experimenter sits, into the hole marked 'internet'
open a finder window (windows explorer window?) and connect to the subject file on opus for the in-lab visit a. may need to login to opus, see directions from chris as needed
open a finder window for the experiment you're transferring to (e.g. 10month seedlings)
transfer the 8 new audio files from e.g. 02_10/in-lab/stimuli/audio into 10month seedlings/library/audio a. if it says it already has the audio files, this is okay you don't need to recopy them
do the same for the 8 new image files from e.g. 02_10/in-lab visit/stimuli/images into 10month seedlings/library/images a. here, if it says it already has the image, make sure the file was correctly labeled; if for instance we had a very specific diaper, the image should be called e.g. diaper2.jpg (or whatever its' called in the datasource and stimuli xlsx files)
from opus open the datasource file called e.g. 02_10_datasource.xlsx on the eye tracking pc, iris a. at the top, click to 'enable editing' a. click view->arrange all so that you can see the contents of the file (this is a hack bc of weird pc/mac stuff) a. save the spreadsheet as a tab-delimited .txt into the myfiles folder to the experiment on iris, e.g. 10month seedlings/myfiles
call it, e.g. [[DataSource1108.txt]] (exact capitalization and no spaces or underscores)
open the experiment and run it as a test subject, if it crashes, look at the message at the top of the python crash log; it will usually be because there is an audio or image file that was misnamed. if this is the case, find the mistake fixed in the following places: a. the actual image or audio file needs to be renamed in the stimuli file for that visit in subj files on opus a. the actual image or audio files needs to be renamed in the library file for the experiment on iris a. the stimuli.xls and the datasource.xls, and the datasource .txt files in the subject folder need to have the stimulus named correctly
unplug the internet cord.