Spaces:
Sleeping
Sleeping
Update infer.py
Browse files
infer.py
CHANGED
@@ -643,7 +643,7 @@ with gr.Blocks() as app:
|
|
643 |
visible=False,
|
644 |
interactive=True,
|
645 |
)
|
646 |
-
refresh_model = gr.Button("
|
647 |
clean_button = gr.Button("Clear Model from memory", variant="primary")
|
648 |
refresh_model.click(
|
649 |
fn=check_models, inputs=[], outputs=[sid, file_index]
|
@@ -653,26 +653,26 @@ with gr.Blocks() as app:
|
|
653 |
selected_model = gr.Markdown(value="# <center> No model selected")
|
654 |
with gr.Row():
|
655 |
with gr.Column():
|
656 |
-
vc_audio_mode = gr.Dropdown(label="Input voice", choices=["
|
657 |
-
# Youtube
|
658 |
-
vc_download_audio = gr.Dropdown(label="Provider", choices=["Youtube"], allow_custom_value=False, visible=True, value="Youtube", info="Select provider (Default: Youtube)")
|
659 |
-
vc_link = gr.Textbox(label="Youtube URL", visible=True, info="Example: https://www.youtube.com/watch?v=Nc0sB1Bmf-A", placeholder="https://www.youtube.com/watch?v=...")
|
660 |
-
vc_log_yt = gr.Textbox(label="Output Information", visible=True, interactive=False)
|
661 |
-
vc_download_button = gr.Button("(2)Download Audio", variant="primary", visible=True)
|
662 |
-
vc_audio_preview = gr.Audio(label="Downloaded Audio Preview", visible=True)
|
663 |
# Input
|
664 |
vc_input = gr.Textbox(label="Input audio path", visible=False)
|
665 |
# Upload
|
666 |
-
vc_microphone_mode = gr.Checkbox(label="Use Microphone", value=False, visible=
|
667 |
-
vc_upload = gr.Audio(label="Upload audio file", source="upload", visible=
|
|
|
|
|
|
|
|
|
|
|
|
|
668 |
# TTS
|
669 |
tts_text = gr.Textbox(label="TTS text", info="Text to speech input", visible=False)
|
670 |
tts_voice = gr.Dropdown(label="Edge-tts speaker", choices=voices, visible=False, allow_custom_value=False, value="en-US-AnaNeural-Female")
|
671 |
# Splitter
|
672 |
vc_split_model = gr.Dropdown(label="Splitter Model", choices=["hdemucs_mmi", "htdemucs", "htdemucs_ft", "mdx", "mdx_q", "mdx_extra_q"], allow_custom_value=False, visible=True, value="htdemucs", info="Select the splitter model (Default: htdemucs)")
|
673 |
vc_split_log = gr.Textbox(label="Output Information", visible=True, interactive=False)
|
674 |
-
vc_split_yt = gr.Button("
|
675 |
-
vc_split = gr.Button("
|
676 |
vc_vocal_preview = gr.Audio(label="Vocal Preview", interactive=False, visible=True)
|
677 |
vc_inst_preview = gr.Audio(label="Instrumental Preview", interactive=False, visible=True)
|
678 |
with gr.Column():
|
@@ -685,7 +685,7 @@ with gr.Blocks() as app:
|
|
685 |
label="Pitch extraction algorithm",
|
686 |
info=f0method_info,
|
687 |
choices=f0method_mode,
|
688 |
-
value="
|
689 |
interactive=True,
|
690 |
)
|
691 |
index_rate0 = gr.Slider(
|
@@ -737,7 +737,7 @@ with gr.Blocks() as app:
|
|
737 |
with gr.Column():
|
738 |
vc_log = gr.Textbox(label="Output Information", interactive=False)
|
739 |
vc_output = gr.Audio(label="Output Audio", interactive=False)
|
740 |
-
vc_convert = gr.Button("
|
741 |
vc_vocal_volume = gr.Slider(
|
742 |
minimum=0,
|
743 |
maximum=10,
|
@@ -759,7 +759,7 @@ with gr.Blocks() as app:
|
|
759 |
visible=True
|
760 |
)
|
761 |
vc_combined_output = gr.Audio(label="Output Combined Audio", visible=True)
|
762 |
-
vc_combine = gr.Button("
|
763 |
vc_convert.click(
|
764 |
vc_single,
|
765 |
[
|
|
|
643 |
visible=False,
|
644 |
interactive=True,
|
645 |
)
|
646 |
+
refresh_model = gr.Button("Refresh model list", variant="primary")
|
647 |
clean_button = gr.Button("Clear Model from memory", variant="primary")
|
648 |
refresh_model.click(
|
649 |
fn=check_models, inputs=[], outputs=[sid, file_index]
|
|
|
653 |
selected_model = gr.Markdown(value="# <center> No model selected")
|
654 |
with gr.Row():
|
655 |
with gr.Column():
|
656 |
+
vc_audio_mode = gr.Dropdown(label="Input voice", choices=["Input path", "Upload audio", "Youtube", "TTS Audio"], allow_custom_value=False, value="Upload audio")
|
|
|
|
|
|
|
|
|
|
|
|
|
657 |
# Input
|
658 |
vc_input = gr.Textbox(label="Input audio path", visible=False)
|
659 |
# Upload
|
660 |
+
vc_microphone_mode = gr.Checkbox(label="Use Microphone", value=False, visible=True, interactive=True)
|
661 |
+
vc_upload = gr.Audio(label="Upload audio file", source="upload", visible=True, interactive=True)
|
662 |
+
# Youtube
|
663 |
+
vc_download_audio = gr.Dropdown(label="Provider", choices=["Youtube"], allow_custom_value=False, visible=False, value="Youtube", info="Select provider (Default: Youtube)")
|
664 |
+
vc_link = gr.Textbox(label="Youtube URL", visible=False, info="Example: https://www.youtube.com/watch?v=Nc0sB1Bmf-A", placeholder="https://www.youtube.com/watch?v=...")
|
665 |
+
vc_log_yt = gr.Textbox(label="Output Information", visible=False, interactive=False)
|
666 |
+
vc_download_button = gr.Button("Download Audio", variant="primary", visible=False)
|
667 |
+
vc_audio_preview = gr.Audio(label="Downloaded Audio Preview", visible=False)
|
668 |
# TTS
|
669 |
tts_text = gr.Textbox(label="TTS text", info="Text to speech input", visible=False)
|
670 |
tts_voice = gr.Dropdown(label="Edge-tts speaker", choices=voices, visible=False, allow_custom_value=False, value="en-US-AnaNeural-Female")
|
671 |
# Splitter
|
672 |
vc_split_model = gr.Dropdown(label="Splitter Model", choices=["hdemucs_mmi", "htdemucs", "htdemucs_ft", "mdx", "mdx_q", "mdx_extra_q"], allow_custom_value=False, visible=True, value="htdemucs", info="Select the splitter model (Default: htdemucs)")
|
673 |
vc_split_log = gr.Textbox(label="Output Information", visible=True, interactive=False)
|
674 |
+
vc_split_yt = gr.Button("Split Audio", variant="primary", visible=False)
|
675 |
+
vc_split = gr.Button("Split Audio", variant="primary", visible=True)
|
676 |
vc_vocal_preview = gr.Audio(label="Vocal Preview", interactive=False, visible=True)
|
677 |
vc_inst_preview = gr.Audio(label="Instrumental Preview", interactive=False, visible=True)
|
678 |
with gr.Column():
|
|
|
685 |
label="Pitch extraction algorithm",
|
686 |
info=f0method_info,
|
687 |
choices=f0method_mode,
|
688 |
+
value="pm",
|
689 |
interactive=True,
|
690 |
)
|
691 |
index_rate0 = gr.Slider(
|
|
|
737 |
with gr.Column():
|
738 |
vc_log = gr.Textbox(label="Output Information", interactive=False)
|
739 |
vc_output = gr.Audio(label="Output Audio", interactive=False)
|
740 |
+
vc_convert = gr.Button("Convert", variant="primary")
|
741 |
vc_vocal_volume = gr.Slider(
|
742 |
minimum=0,
|
743 |
maximum=10,
|
|
|
759 |
visible=True
|
760 |
)
|
761 |
vc_combined_output = gr.Audio(label="Output Combined Audio", visible=True)
|
762 |
+
vc_combine = gr.Button("Combine",variant="primary", visible=True)
|
763 |
vc_convert.click(
|
764 |
vc_single,
|
765 |
[
|