kokuma commited on
Commit
a935752
·
verified ·
1 Parent(s): d34cea4

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +5 -5
app.py CHANGED
@@ -54,9 +54,9 @@ def change_language(lang):
54
  text_features = text_features.cpu().numpy()
55
  else:
56
  text_features = None
57
- correct_text = gr.Text(f"Respuesta correcta: ''. Question 1/{len(babel_imagenet[lang][0])} ", label="Partida")
58
  player_score_text = gr.Text(f" ", label="Personas")
59
- clip_score_text = gr.Text(f" ", label="Robots")
60
 
61
  return text_features, -1, class_order, correct_text, player_score_text, clip_score_text, 0, 0
62
 
@@ -73,8 +73,8 @@ def select(idx, lang, choice, correct, model_choice, player_score, clip_score, c
73
  clip_score = clip_score + int(model_correct)
74
 
75
  correct_text = gr.Text(f"Respuesta correcta: '{correct_name}'. Pregunta {idx+1}/{len(babel_imagenet[lang][0])} ", label="Partida")
76
- player_score_text = gr.Text(f"{player_choice} {'✅' if player_correct else '❌'} (Puntos: {player_score}) ", label="Personas")
77
- clip_score_text = gr.Text(f"{model_choice_name} {'✅' if model_correct else '❌'} (Puntos: {clip_score})", label="mSigLIP")
78
 
79
  return correct_text, player_score_text, clip_score_text, player_score, clip_score
80
 
@@ -199,7 +199,7 @@ with (gr.Blocks(title="Babel-ImageNet Quiz") as demo):
199
  gr.Markdown("""
200
  # ¿Eres más lista 🤓 que CLIP 🤖?
201
 
202
- <small>por Gregor Geigle, WüNLP & Computer Vision Lab, University of Würzburg y Both.rocks!</small>
203
 
204
  """)
205
  # language select dropdown
 
54
  text_features = text_features.cpu().numpy()
55
  else:
56
  text_features = None
57
+ correct_text = gr.Text(f"Respuesta correcta: ''. Pregunta 1/{len(babel_imagenet[lang][0])} ", label="Partida")
58
  player_score_text = gr.Text(f" ", label="Personas")
59
+ clip_score_text = gr.Text(f" ", label="mSigLIP")
60
 
61
  return text_features, -1, class_order, correct_text, player_score_text, clip_score_text, 0, 0
62
 
 
73
  clip_score = clip_score + int(model_correct)
74
 
75
  correct_text = gr.Text(f"Respuesta correcta: '{correct_name}'. Pregunta {idx+1}/{len(babel_imagenet[lang][0])} ", label="Partida")
76
+ player_score_text = gr.Text(f"{'✅' if player_correct else '❌'} {player_choice} (Puntos: {player_score}) ", label="Personas")
77
+ clip_score_text = gr.Text(f"{'✅' if model_correct else '❌'} {model_choice_name} (Puntos: {clip_score})", label="mSigLIP")
78
 
79
  return correct_text, player_score_text, clip_score_text, player_score, clip_score
80
 
 
199
  gr.Markdown("""
200
  # ¿Eres más lista 🤓 que CLIP 🤖?
201
 
202
+ <small>Por Gregor Geigle, WüNLP & Computer Vision Lab, University of Würzburg y Both.rocks!</small>
203
 
204
  """)
205
  # language select dropdown