brindhamanick commited on
Commit
62eb796
·
verified ·
1 Parent(s): 7ff1a6b

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +12 -12
app.py CHANGED
@@ -1957,7 +1957,7 @@ def GradioSetup(UTheme=gr.themes.Soft()):
1957
  )
1958
  with gr.Tabs():
1959
  with gr.TabItem(i18n("Model Inference")):
1960
- with gr.Row():
1961
  sid0 = gr.Dropdown(label=i18n("Inferencing voice:"), choices=sorted(names), value=default_weight)
1962
  refresh_button = gr.Button(i18n("Refresh"), variant="primary")
1963
  clean_button = gr.Button(i18n("Unload voice to save GPU memory"), variant="primary")
@@ -1965,7 +1965,7 @@ def GradioSetup(UTheme=gr.themes.Soft()):
1965
 
1966
 
1967
  with gr.TabItem(i18n("Single")):
1968
- with gr.Row():
1969
  spk_item = gr.Slider(
1970
  minimum=0,
1971
  maximum=2333,
@@ -1978,7 +1978,7 @@ def GradioSetup(UTheme=gr.themes.Soft()):
1978
 
1979
 
1980
  with gr.Group():
1981
- with gr.Row():
1982
  with gr.Column(): # First column for audio-related inputs
1983
  dropbox = gr.File(label=i18n("Drag your audio here:"))
1984
 
@@ -2035,7 +2035,7 @@ def GradioSetup(UTheme=gr.themes.Soft()):
2035
 
2036
  # Advanced settings container
2037
  with gr.Column(visible=False) as advanced_settings: # Initially hidden
2038
- with gr.Row(label = i18n("Advanced Settings"), open = False):
2039
  with gr.Column():
2040
  f0method0 = gr.Radio(
2041
  label=i18n(
@@ -2255,12 +2255,12 @@ def GradioSetup(UTheme=gr.themes.Soft()):
2255
 
2256
  but0 = gr.Button(i18n("Convert"), variant="primary").style(full_width=True)
2257
 
2258
- with gr.Row(): # Defines output info + output audio download after conversion
2259
  vc_output1 = gr.Textbox(label=i18n("Output information:"))
2260
  vc_output2 = gr.Audio(label=i18n("Export audio (click on the three dots in the lower right corner to download)"))
2261
 
2262
  with gr.Group(): # I think this defines the big convert button
2263
- with gr.Row():
2264
  but0.click(
2265
  vc.vc_single,
2266
  [
@@ -2291,7 +2291,7 @@ def GradioSetup(UTheme=gr.themes.Soft()):
2291
  gr.Markdown(
2292
  value=i18n("Batch conversion. Enter the folder containing the audio files to be converted or upload multiple audio files. The converted audio will be output in the specified folder (default: 'opt').")
2293
  )
2294
- with gr.Row():
2295
  with gr.Column():
2296
  vc_transform1 = gr.Number(
2297
  label=i18n("Transpose (integer, number of semitones, raise by an octave: 12, lower by an octave: -12):"), value=0
@@ -2318,7 +2318,7 @@ def GradioSetup(UTheme=gr.themes.Soft()):
2318
  value=0.75,
2319
  interactive=True,
2320
  )
2321
- with gr.Row():
2322
  dir_input = gr.Textbox(
2323
  label=i18n("Enter the path of the audio folder to be processed (copy it from the address bar of the file manager):"),
2324
  value=os.path.join(now_dir, "audios"),
@@ -2327,7 +2327,7 @@ def GradioSetup(UTheme=gr.themes.Soft()):
2327
  file_count="multiple", label=i18n("You can also input audio files in batches. Choose one of the two options. Priority is given to reading from the folder.")
2328
  )
2329
 
2330
- with gr.Row():
2331
  with gr.Column():
2332
  # Create a checkbox for advanced batch settings
2333
  advanced_settings_batch_checkbox = gr.Checkbox(
@@ -2337,8 +2337,8 @@ def GradioSetup(UTheme=gr.themes.Soft()):
2337
  )
2338
 
2339
  # Advanced batch settings container
2340
- with gr.Row(visible=False) as advanced_settings_batch: # Initially hidden
2341
- with gr.Row(label = i18n("Advanced Settings"), open = False):
2342
  with gr.Column():
2343
  file_index3 = gr.Textbox(
2344
  label=i18n("Feature search database file path:"),
@@ -2367,7 +2367,7 @@ def GradioSetup(UTheme=gr.themes.Soft()):
2367
  interactive=True,
2368
  )
2369
 
2370
- with gr.Row():
2371
  format1 = gr.Radio(
2372
  label=i18n("Export file format"),
2373
  choices=["wav", "flac", "mp3", "m4a"],
 
1957
  )
1958
  with gr.Tabs():
1959
  with gr.TabItem(i18n("Model Inference")):
1960
+ with gr.Accordionow():
1961
  sid0 = gr.Dropdown(label=i18n("Inferencing voice:"), choices=sorted(names), value=default_weight)
1962
  refresh_button = gr.Button(i18n("Refresh"), variant="primary")
1963
  clean_button = gr.Button(i18n("Unload voice to save GPU memory"), variant="primary")
 
1965
 
1966
 
1967
  with gr.TabItem(i18n("Single")):
1968
+ with gr.Accordion():
1969
  spk_item = gr.Slider(
1970
  minimum=0,
1971
  maximum=2333,
 
1978
 
1979
 
1980
  with gr.Group():
1981
+ with gr.Accordion():
1982
  with gr.Column(): # First column for audio-related inputs
1983
  dropbox = gr.File(label=i18n("Drag your audio here:"))
1984
 
 
2035
 
2036
  # Advanced settings container
2037
  with gr.Column(visible=False) as advanced_settings: # Initially hidden
2038
+ with gr.Accordion(label = i18n("Advanced Settings"), open = False):
2039
  with gr.Column():
2040
  f0method0 = gr.Radio(
2041
  label=i18n(
 
2255
 
2256
  but0 = gr.Button(i18n("Convert"), variant="primary").style(full_width=True)
2257
 
2258
+ with gr.Accordion(): # Defines output info + output audio download after conversion
2259
  vc_output1 = gr.Textbox(label=i18n("Output information:"))
2260
  vc_output2 = gr.Audio(label=i18n("Export audio (click on the three dots in the lower right corner to download)"))
2261
 
2262
  with gr.Group(): # I think this defines the big convert button
2263
+ with gr.Accordion():
2264
  but0.click(
2265
  vc.vc_single,
2266
  [
 
2291
  gr.Markdown(
2292
  value=i18n("Batch conversion. Enter the folder containing the audio files to be converted or upload multiple audio files. The converted audio will be output in the specified folder (default: 'opt').")
2293
  )
2294
+ with gr.Accordion():
2295
  with gr.Column():
2296
  vc_transform1 = gr.Number(
2297
  label=i18n("Transpose (integer, number of semitones, raise by an octave: 12, lower by an octave: -12):"), value=0
 
2318
  value=0.75,
2319
  interactive=True,
2320
  )
2321
+ with gr.Accordion():
2322
  dir_input = gr.Textbox(
2323
  label=i18n("Enter the path of the audio folder to be processed (copy it from the address bar of the file manager):"),
2324
  value=os.path.join(now_dir, "audios"),
 
2327
  file_count="multiple", label=i18n("You can also input audio files in batches. Choose one of the two options. Priority is given to reading from the folder.")
2328
  )
2329
 
2330
+ with gr.Accordion():
2331
  with gr.Column():
2332
  # Create a checkbox for advanced batch settings
2333
  advanced_settings_batch_checkbox = gr.Checkbox(
 
2337
  )
2338
 
2339
  # Advanced batch settings container
2340
+ with gr.Accordion(visible=False) as advanced_settings_batch: # Initially hidden
2341
+ with gr.Accordion(label = i18n("Advanced Settings"), open = False):
2342
  with gr.Column():
2343
  file_index3 = gr.Textbox(
2344
  label=i18n("Feature search database file path:"),
 
2367
  interactive=True,
2368
  )
2369
 
2370
+ with gr.Accordion():
2371
  format1 = gr.Radio(
2372
  label=i18n("Export file format"),
2373
  choices=["wav", "flac", "mp3", "m4a"],