Pendrokar commited on
Commit
bece061
1 Parent(s): 15763df

blue links

Browse files
Files changed (2) hide show
  1. README.md +2 -0
  2. app.py +17 -3
README.md CHANGED
@@ -22,4 +22,6 @@ models:
22
  - collabora/whisperspeech
23
  - myshell-ai/OpenVoice
24
  - metavoiceio/metavoice-1B-v0.1
 
 
25
  ---
 
22
  - collabora/whisperspeech
23
  - myshell-ai/OpenVoice
24
  - metavoiceio/metavoice-1B-v0.1
25
+ - amphion/Text-to-Speech
26
+ - LeeSangHoon/HierSpeech_TTS
27
  ---
app.py CHANGED
@@ -426,7 +426,8 @@ def get_leaderboard(reveal_prelim = False):
426
  df = pd.DataFrame(data, columns=['name', 'upvote', 'downvote'])
427
  # df['license'] = df['name'].map(model_license)
428
  df['name'] = df['name'].replace(model_names)
429
- df['name'] = make_link_to_space(df['name'])
 
430
  df['votes'] = df['upvote'] + df['downvote']
431
  # df['score'] = round((df['upvote'] / df['votes']) * 100, 2) # Percentage score
432
 
@@ -453,7 +454,14 @@ def get_leaderboard(reveal_prelim = False):
453
  def make_link_to_space(model_name):
454
  # create a anchor link if a HF space
455
  if '/' in model_name:
456
- return '🤗 <a href="'+ 'https://huggingface.co/spaces/' + model_name + '">' + model_name + '</a>'
 
 
 
 
 
 
 
457
  # otherwise just return the model name
458
  return model_name
459
  def mkuuid(uid):
@@ -565,7 +573,13 @@ def reload(chosenmodel1=None, chosenmodel2=None, userid=None, chose_a=False, cho
565
  with gr.Blocks() as leaderboard:
566
  gr.Markdown(LDESC)
567
  # df = gr.Dataframe(interactive=False, value=get_leaderboard())
568
- df = gr.Dataframe(interactive=False, min_width=0, wrap=True, column_widths=[30, 200, 50, 50])
 
 
 
 
 
 
569
  with gr.Row():
570
  reveal_prelim = gr.Checkbox(label="Reveal preliminary results", info="Show all models, including models with very few human ratings.", scale=1)
571
  reloadbtn = gr.Button("Refresh", scale=3)
 
426
  df = pd.DataFrame(data, columns=['name', 'upvote', 'downvote'])
427
  # df['license'] = df['name'].map(model_license)
428
  df['name'] = df['name'].replace(model_names)
429
+ for i in range(len(df)):
430
+ df['name'][i] = make_link_to_space(df['name'][i])
431
  df['votes'] = df['upvote'] + df['downvote']
432
  # df['score'] = round((df['upvote'] / df['votes']) * 100, 2) # Percentage score
433
 
 
454
  def make_link_to_space(model_name):
455
  # create a anchor link if a HF space
456
  if '/' in model_name:
457
+ style = 'color: var(--link-text-color);text-decoration: underline;text-decoration-style: dotted;'
458
+ return '🤗 <a style="' + style + '" href="'+ 'https://huggingface.co/spaces/' + model_name + '">' + model_name + '</a>'
459
+ # otherwise just return the model name
460
+ return model_name
461
+ def markdown_link_to_space(model_name):
462
+ # create a anchor link if a HF space using markdown syntax
463
+ if '/' in model_name:
464
+ return '🤗 [' + model_name + '](https://huggingface.co/spaces/' + model_name + ')'
465
  # otherwise just return the model name
466
  return model_name
467
  def mkuuid(uid):
 
573
  with gr.Blocks() as leaderboard:
574
  gr.Markdown(LDESC)
575
  # df = gr.Dataframe(interactive=False, value=get_leaderboard())
576
+ df = gr.Dataframe(
577
+ interactive=False,
578
+ min_width=0,
579
+ wrap=True,
580
+ column_widths=[30, 200, 50, 50],
581
+ datatype=["str", "html", "number", "number"]
582
+ )
583
  with gr.Row():
584
  reveal_prelim = gr.Checkbox(label="Reveal preliminary results", info="Show all models, including models with very few human ratings.", scale=1)
585
  reloadbtn = gr.Button("Refresh", scale=3)