Kangarroar commited on
Commit
51f866c
1 Parent(s): 79f1f37

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -4
app.py CHANGED
@@ -32,7 +32,9 @@ def render_audio(ckpt_temp_file, config_temp_file, audio_temp_file, title, title
32
  logging.getLogger('numba').setLevel(logging.WARNING)
33
  title = int(title)
34
  title2 = int(title2)
35
-
 
 
36
  project_name = "Unnamed"
37
  model_path = ckpt_temp_file
38
  config_path= config_temp_file
@@ -50,9 +52,6 @@ def render_audio(ckpt_temp_file, config_temp_file, audio_temp_file, title, title
50
  with st.spinner("Rendering Audio..."):
51
  f0_tst, f0_pred, audio = run_clip(svc_model,file_path=wav_fn, key=key, acc=title2, use_crepe=Crepe, use_pe=False, thre=0.05,
52
  use_gt_mel=use_mel_as_base, add_noise_step=noise_step,project_name=project_name,out_path=wav_gen)
53
-    formant_shift_ratio_str = title3
54
-    formant_shift_ratio = float(formant_shift_ratio_str)
55
-     
56
      # If the formant shift ratio is not equal to 1.0, change the gender of the sound using parselmouth
57
     if formant_shift_ratio != 1.0:
58
         sound = parselmouth.Sound(wav_gen)
 
32
  logging.getLogger('numba').setLevel(logging.WARNING)
33
  title = int(title)
34
  title2 = int(title2)
35
+ formant_shift_ratio_str = title3
36
+    formant_shift_ratio = float(formant_shift_ratio_str)
37
+     
38
  project_name = "Unnamed"
39
  model_path = ckpt_temp_file
40
  config_path= config_temp_file
 
52
  with st.spinner("Rendering Audio..."):
53
  f0_tst, f0_pred, audio = run_clip(svc_model,file_path=wav_fn, key=key, acc=title2, use_crepe=Crepe, use_pe=False, thre=0.05,
54
  use_gt_mel=use_mel_as_base, add_noise_step=noise_step,project_name=project_name,out_path=wav_gen)
 
 
 
55
      # If the formant shift ratio is not equal to 1.0, change the gender of the sound using parselmouth
56
     if formant_shift_ratio != 1.0:
57
         sound = parselmouth.Sound(wav_gen)