Blane187 commited on
Commit
92f5cdf
·
verified ·
1 Parent(s): 7ef691e

Update demo.py

Browse files
Files changed (1) hide show
  1. demo.py +21 -16
demo.py CHANGED
@@ -55,22 +55,27 @@ def run_inference(model_name, pitch, input_path, f0_method, save_as, index_rate,
55
  with gr.Blocks() as demo:
56
  with gr.Row():
57
  gr.Markdown("# RVC V2 - EASY GUI")
58
- with gr.Row():
59
- model_name = gr.Textbox(label="Model Name For Inference")
60
- with gr.Row():
61
- input_path = gr.Audio(label="Input Audio Path", type="filepath")
62
- pitch = gr.Slider(minimum=-12, maximum=12, step=1, label="Pitch", value=0)
63
- f0_method = gr.Dropdown(choices=["rmvpe", "pm", "harvest"], label="f0 Method", value="rmvpe")
64
- index_rate = gr.Slider(minimum=0, maximum=1, step=0.01, label="Index Rate", value=0.5)
65
- volume_normalization = gr.Slider(minimum=0, maximum=1, step=0.01, label="Volume Normalization", value=0)
66
- consonant_protection = gr.Slider(minimum=0, maximum=1, step=0.01, label="Consonant Protection", value=0.5)
67
- save_as = gr.Textbox(value="/content/RVC/audios/output_audio.wav", label="Output Audio Path")
 
 
 
 
 
 
 
 
 
 
 
68
 
69
- run_btn = gr.Button("Run Inference")
70
- with gr.Row():
71
- output_message = gr.Textbox(label="Output Message")
72
- output_audio = gr.Audio(label="Output Audio",interactive=False)
73
 
74
- #run_btn.click(run_inference, [model_name, pitch, input_path, f0_method, save_as, index_rate, volume_normalization, consonant_protection], output_message)
75
-
76
  demo.launch()
 
55
  with gr.Blocks() as demo:
56
  with gr.Row():
57
  gr.Markdown("# RVC V2 - EASY GUI")
58
+ with gr.Tab("Inference"):
59
+ with gr.Row():
60
+ model_name = gr.Textbox(label="Model Name For Inference")
61
+ with gr.Row():
62
+ input_path = gr.Audio(label="Input Audio Path", type="filepath")
63
+ with gr.Row():
64
+ with gr.Accordion("Inference Settings"):
65
+ pitch = gr.Slider(minimum=-12, maximum=12, step=1, label="Pitch", value=0)
66
+ f0_method = gr.Dropdown(choices=["rmvpe", "pm", "harvest"], label="f0 Method", value="rmvpe")
67
+ index_rate = gr.Slider(minimum=0, maximum=1, step=0.01, label="Index Rate", value=0.5)
68
+ volume_normalization = gr.Slider(minimum=0, maximum=1, step=0.01, label="Volume Normalization", value=0)
69
+ consonant_protection = gr.Slider(minimum=0, maximum=1, step=0.01, label="Consonant Protection", value=0.5)
70
+ with gr.Row():
71
+ save_as = gr.Textbox(value="/content/RVC/audios/output_audio.wav", label="Output Audio Path")
72
+
73
+ run_btn = gr.Button("Run Inference")
74
+ with gr.Row():
75
+ output_message = gr.Textbox(label="Output Message",interactive=False)
76
+ output_audio = gr.Audio(label="Output Audio",interactive=False)
77
+ #run_btn.click(run_inference, [model_name, pitch, input_path, f0_method, save_as, index_rate, volume_normalization, consonant_protection], output_message)
78
+
79
 
 
 
 
 
80
 
 
 
81
  demo.launch()