Files changed (1) hide show
  1. app.py +32 -29
app.py CHANGED
@@ -229,7 +229,7 @@ def bytecover(sig, bytecover_match_ct=3, clap_match_ct=3, chunk_size=None):
229
  # normalized_similarity = (match[0] - 0.5) * 2
230
  # color_list = [int(min(400 * normalized_similarity, 200)), int(min(400 * (1 - normalized_similarity), 200)), 0, 20]
231
 
232
- output_md += f'{format_time(match_time)}: \n [{song_title} by {song_artists}]({song_link}) \n Genre: {song_genre} \n Similarity: {match[0]}\n\n'
233
 
234
  # label = AudioLabel(t=match_time,
235
  # label=f'{song_title}',
@@ -463,7 +463,32 @@ with gr.Blocks() as demo:
463
 
464
  # mask settings
465
  with gr.Column():
466
- with gr.Accordion("manual controls", open=True):
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
467
  periodic_p = gr.Slider(
468
  label="periodic prompt",
469
  minimum=0,
@@ -578,10 +603,11 @@ with gr.Blocks() as demo:
578
  maskimg = gr.Image(
579
  label="mask image",
580
  interactive=False,
581
- type="filepath"
 
582
  )
583
 
584
- with gr.Accordion("extras ", open=False):
585
  pitch_shift_amt = gr.Slider(
586
  label="pitch shift amount (semitones)",
587
  minimum=-12,
@@ -601,7 +627,7 @@ with gr.Blocks() as demo:
601
 
602
 
603
 
604
- with gr.Accordion("sampling settings", open=False):
605
  sampletemp = gr.Slider(
606
  label="sample temperature",
607
  minimum=0.1,
@@ -654,36 +680,13 @@ with gr.Blocks() as demo:
654
  label="seed (0 for random)",
655
  value=0,
656
  precision=0,
 
657
  )
658
 
659
 
660
  # mask settings
661
  with gr.Column():
662
 
663
- model_choice = gr.Dropdown(
664
- label="model choice",
665
- choices=list(interface.available_models()),
666
- value=init_model_choice,
667
- visible=True
668
- )
669
-
670
-
671
- vamp_button = gr.Button("generate (vamp)!!!")
672
-
673
-
674
- audio_outs = []
675
- use_as_input_btns = []
676
- for i in range(1):
677
- with gr.Column():
678
- audio_outs.append(gr.Audio(
679
- label=f"output audio {i+1}",
680
- interactive=False,
681
- type="numpy"
682
- ))
683
- use_as_input_btns.append(
684
- gr.Button(f"use as input (feedback)")
685
- )
686
-
687
  #thank_you = gr.Markdown("")
688
 
689
  labels = gr.Markdown(label="output labels")
 
229
  # normalized_similarity = (match[0] - 0.5) * 2
230
  # color_list = [int(min(400 * normalized_similarity, 200)), int(min(400 * (1 - normalized_similarity), 200)), 0, 20]
231
 
232
+ output_md += f'{format_time(match_time)}: \n [{song_title} by {song_artists}]({song_link}) \n Genre: {song_genre} \n Similarity: {match[0]:.2f}\n\n'
233
 
234
  # label = AudioLabel(t=match_time,
235
  # label=f'{song_title}',
 
463
 
464
  # mask settings
465
  with gr.Column():
466
+
467
+ model_choice = gr.Dropdown(
468
+ label="model choice",
469
+ choices=list(interface.available_models()),
470
+ value=init_model_choice,
471
+ visible=True
472
+ )
473
+
474
+
475
+ vamp_button = gr.Button("generate (vamp)!!!")
476
+
477
+
478
+ audio_outs = []
479
+ use_as_input_btns = []
480
+ for i in range(1):
481
+ with gr.Column():
482
+ audio_outs.append(gr.Audio(
483
+ label=f"output audio {i+1}",
484
+ interactive=False,
485
+ type="numpy"
486
+ ))
487
+ use_as_input_btns.append(
488
+ gr.Button(f"use as input (feedback)")
489
+ )
490
+
491
+ with gr.Accordion("manual controls", open=True, visible=False):
492
  periodic_p = gr.Slider(
493
  label="periodic prompt",
494
  minimum=0,
 
603
  maskimg = gr.Image(
604
  label="mask image",
605
  interactive=False,
606
+ type="filepath",
607
+ visible=False
608
  )
609
 
610
+ with gr.Accordion("extras ", open=False, visible=False):
611
  pitch_shift_amt = gr.Slider(
612
  label="pitch shift amount (semitones)",
613
  minimum=-12,
 
627
 
628
 
629
 
630
+ with gr.Accordion("sampling settings", open=False, visible=False):
631
  sampletemp = gr.Slider(
632
  label="sample temperature",
633
  minimum=0.1,
 
680
  label="seed (0 for random)",
681
  value=0,
682
  precision=0,
683
+ visible=False
684
  )
685
 
686
 
687
  # mask settings
688
  with gr.Column():
689
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
690
  #thank_you = gr.Markdown("")
691
 
692
  labels = gr.Markdown(label="output labels")