Commit 5864d76a authored by Vlad Dumitru's avatar Vlad Dumitru
Browse files

random sample of 5 from Luisa and Lukas each for the Emotions quiz

parent a779b2d0
Pipeline #6873 failed with stages
in 2 minutes and 2 seconds
[
"01-wir-hoeren-nicht-alle-alles-gleich.json",
"02-wir-hoeren-dinge-die-nicht-gesagt-wurden.json",
"03-was-denkst-du-wie-fuehlen-sie-sich.json",
"04-mcgurk-unsere-augen-hoeren-mit.json"
]
[{"type": "multiple-choice", "image": "luisa.jpg", "text": "Wie f\u00fchlt sich die Sprecherin?", "choices": ["\ud83d\ude00", "\ud83d\ude41", "\ud83d\ude20"], "media": {"type": "audio", "file": "Saskia/Happy/Saskia_Schreiben.wav"}}, {"type": "multiple-choice", "image": "lucas.jpg", "text": "Wie f\u00fchlt sich der Sprecher?", "choices": ["\ud83d\ude00", "\ud83d\ude41", "\ud83d\ude20"], "media": {"type": "audio", "file": "Eric/Happy/Eric_Helfen.wav"}}, {"type": "multiple-choice", "image": "luisa.jpg", "text": "Wie f\u00fchlt sich die Sprecherin?", "choices": ["\ud83d\ude00", "\ud83d\ude41", "\ud83d\ude20"], "media": {"type": "audio", "file": "Saskia/Angry/Saskia_Bus.wav"}}, {"type": "multiple-choice", "image": "lucas.jpg", "text": "Wie f\u00fchlt sich der Sprecher?", "choices": ["\ud83d\ude00", "\ud83d\ude41", "\ud83d\ude20"], "media": {"type": "audio", "file": "Eric/Happy/Eric_Eis.wav"}}, {"type": "multiple-choice", "image": "luisa.jpg", "text": "Wie f\u00fchlt sich die Sprecherin?", "choices": ["\ud83d\ude00", "\ud83d\ude41", "\ud83d\ude20"], "media": {"type": "audio", "file": "Saskia/Sad/Saskia_Bus.wav"}}, {"type": "multiple-choice", "image": "lucas.jpg", "text": "Wie f\u00fchlt sich der Sprecher?", "choices": ["\ud83d\ude00", "\ud83d\ude41", "\ud83d\ude20"], "media": {"type": "audio", "file": "Stefan/Angry/Stefan_Schreiben.wav"}}, {"type": "multiple-choice", "image": "luisa.jpg", "text": "Wie f\u00fchlt sich die Sprecherin?", "choices": ["\ud83d\ude00", "\ud83d\ude41", "\ud83d\ude20"], "media": {"type": "audio", "file": "Saskia/Angry/Saskia_Eis.wav"}}, {"type": "multiple-choice", "image": "lucas.jpg", "text": "Wie f\u00fchlt sich der Sprecher?", "choices": ["\ud83d\ude00", "\ud83d\ude41", "\ud83d\ude20"], "media": {"type": "audio", "file": "Stefan/Sad/Stefan_Helfen.wav"}}, {"type": "multiple-choice", "image": "luisa.jpg", "text": "Wie f\u00fchlt sich die Sprecherin?", "choices": ["\ud83d\ude00", "\ud83d\ude41", "\ud83d\ude20"], "media": {"type": "audio", "file": "Saskia/Happy/Saskia_Helfen.wav"}}, {"type": "multiple-choice", "image": "lucas.jpg", "text": "Wie f\u00fchlt sich der Sprecher?", "choices": ["\ud83d\ude00", "\ud83d\ude41", "\ud83d\ude20"], "media": {"type": "audio", "file": "Stefan/Happy/Stefan_Eis.wav"}}]
......@@ -16,7 +16,8 @@ if __name__ == '__main__':
root_dir = sys.argv[1]
questions = []
luisa_questions = []
lukas_questions = []
for name in names:
for emotion in emotions:
......@@ -32,8 +33,13 @@ if __name__ == '__main__':
}
}
questions.append(question)
if question['image'] == 'luisa.jpg':
luisa_questions.append(question)
else:
lukas_questions.append(question)
random.shuffle(questions)
luisa_random_sample = random.sample(luisa_questions, 5)
lukas_random_sample = random.sample(lukas_questions, 5)
questions = [val for pair in zip(luisa_random_sample, lukas_random_sample) for val in pair]
print(json.dumps(questions))
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment