@@ -43,7 +43,7 @@ def __init__(self, agg, model_path, device, is_half, tta=False):
4343 self .model = model
4444
4545 def _path_audio_ (
46- self , music_file , ins_root = None , vocal_root = None , format = "flac" , is_hp3 = False
46+ self , music_file , ins_root = None , vocal_root = None , format = "flac"
4747 ):
4848 if ins_root is None and vocal_root is None :
4949 return "No save root."
@@ -123,10 +123,7 @@ def _path_audio_(
123123 else :
124124 wav_instrument = spec_utils .cmb_spectrogram_to_wave (y_spec_m , self .mp )
125125 logger .info ("%s instruments done" % name )
126- if is_hp3 == True :
127- head = "vocal_"
128- else :
129- head = "instrument_"
126+ head = "instrument_"
130127 if format in ["wav" , "flac" ]:
131128 sf .write (
132129 os .path .join (
@@ -149,10 +146,7 @@ def _path_audio_(
149146 opt_format_path = path [:- 4 ] + ".%s" % format
150147 downsample_audio (path , opt_format_path , format )
151148 if vocal_root is not None :
152- if is_hp3 == True :
153- head = "instrument_"
154- else :
155- head = "vocal_"
149+ head = "vocal_"
156150 if self .data ["high_end_process" ].startswith ("mirroring" ):
157151 input_high_end_ = spec_utils .mirroring (
158152 self .data ["high_end_process" ], v_spec_m , input_high_end , self .mp
@@ -213,7 +207,7 @@ def __init__(self, agg, model_path, device, is_half, tta=False):
213207 self .model = model
214208
215209 def _path_audio_ (
216- self , music_file , vocal_root = None , ins_root = None , format = "flac" , is_hp3 = False
210+ self , music_file , vocal_root = None , ins_root = None , format = "flac"
217211 ): # 3个VR模型vocal和ins是反的
218212 if ins_root is None and vocal_root is None :
219213 return "No save root."
0 commit comments