r3gm commited on
Commit
23d65ab
·
verified ·
1 Parent(s): f5db5c5

Update src/rvc.py

Browse files
Files changed (1) hide show
  1. src/rvc.py +3 -1
src/rvc.py CHANGED
@@ -109,6 +109,8 @@ class Config:
109
 
110
  def load_hubert(device, is_half, model_path):
111
  from fairseq import checkpoint_utils
 
 
112
 
113
  models, saved_cfg, task = checkpoint_utils.load_model_ensemble_and_task([model_path], suffix='', )
114
  hubert = models[0]
@@ -173,4 +175,4 @@ def rvc_infer(index_path, index_rate, input_path, output_path, pitch_change, f0_
173
  )
174
 
175
  wavfile.write(output_path, tgt_sr, audio_opt)
176
- working_path = output_path
 
109
 
110
  def load_hubert(device, is_half, model_path):
111
  from fairseq import checkpoint_utils
112
+ import fairseq
113
+ torch.serialization.add_safe_globals([fairseq.data.dictionary.Dictionary])
114
 
115
  models, saved_cfg, task = checkpoint_utils.load_model_ensemble_and_task([model_path], suffix='', )
116
  hubert = models[0]
 
175
  )
176
 
177
  wavfile.write(output_path, tgt_sr, audio_opt)
178
+ working_path = output_path