I want to create an experiment in psychopy. In this experiment I want perhaps 300…
- User
I want to create an experiment in psychopy. In this experiment I want perhaps 300 observers to rate 400 reference images. These 400 images should be drawn from 1028 images that consist of 4 categories: animals, people, nature, food. The images can be altered by 3 distortions, such as blur or saturation and each distortion can be applied at 3 levels. I want each observer to rate an equal amount of categories and the distortions should also be evenly applied to each category. In the end I want that all of the 1028 reference images and their different distortions + levels have been rated approximately the same number of times. How can I best achieve this?
- Assistant
To achieve this, you can follow these steps:
-
Divide the 1028 images into 4 categories, with a roughly equal number of images in each category. For the sake of this example, let's say we have 257 images in each category (animals, people, nature, food).
-
For each category, apply the 3 distortions at 3 levels each, creating 9 distorted versions of each image. You will now have 10 versions of each image (1 original + 9 distorted).
-
To ensure each observer rates an equal number of categories, assign 100 images in each category to each observer. Since you have 400 images to be rated by each observer, this will result in a fair distribution of categories per observer (100 animals, 100 people, 100 nature, 100 food).
-
- User
I want to implement this in psychopy please propse me code that follows your plan. Assume the following: The reference image categories are in groups of 256. The first are animals, the second people the third nature and fourth is food. Thereby there is a total of 1028 reference images.
Each image can have distortion 01, 02 or 03 applied to them. The distortion can then have three levels: A, B or C. An undistorted image could then for instance be 153.jpg which would be an original animal photo. A distorted image could be 394_01_B.jpg which would be a people image distorted by distortion 01 at level B. It will not need to be exactly 400 images if a different amount will guarantee full counterbalance within observers. Also remember that all reference images should receive a similar amount of ratings if possible.
- Assistant
- User
Please summarize my question to a forum post in which I ask for help and present the solution you give here as a starting point.
- Assistant
Subject: Help with implementing a balanced image rating experiment in PsychoPy
Hi everyone,
I need help with implementing an experiment in PsychoPy where I want observers to rate a set of images.
Here is my experimental design:
- Total of 1028 reference images, evenly divided into 4 categories: animals, people, nature, and food (256 images per category).
- Each image can have 3 distortions applied to them (01, 02, 03), and each distortion has 3 levels (A, B, C).
- I want approximately 300 observers to rate around 400 reference images each such that:
- Each observer rates an equal number of images from each of the 4 categories.
- The distortions and levels are evenly applied within each category.
- All reference images should receive a similar number of ratings if possible.
A helpful contributor suggested the following initial solution, which involves generating separate condition files for each observer before running the experiment: