NoCrypt commited on
Commit
546e179
1 Parent(s): ddde641

download repo manually

Browse files
Files changed (1) hide show
  1. app.py +3 -1
app.py CHANGED
@@ -10,6 +10,8 @@ import gradio as gr
10
  import librosa
11
  import torch
12
  from fairseq import checkpoint_utils
 
 
13
 
14
  from config import Config
15
  from lib.infer_pack.models import (
@@ -37,7 +39,7 @@ tts_voice_list = asyncio.get_event_loop().run_until_complete(edge_tts.list_voice
37
  tts_voices = [f"{v['ShortName']}-{v['Gender']}" for v in tts_voice_list]
38
 
39
  # RVC models
40
- model_root = "weights"
41
  models = [d for d in os.listdir(model_root) if os.path.isdir(f"{model_root}/{d}")]
42
  models.sort()
43
 
 
10
  import librosa
11
  import torch
12
  from fairseq import checkpoint_utils
13
+ from huggingface_hub import snapshot_download
14
+
15
 
16
  from config import Config
17
  from lib.infer_pack.models import (
 
39
  tts_voices = [f"{v['ShortName']}-{v['Gender']}" for v in tts_voice_list]
40
 
41
  # RVC models
42
+ model_root = snapshot_download(repo_id="NoCrypt/miku_RVC", token=os.environ["TOKEN"])
43
  models = [d for d in os.listdir(model_root) if os.path.isdir(f"{model_root}/{d}")]
44
  models.sort()
45