Update clear cuda cache

This commit is contained in:
ylzz1997 2023-03-23 20:10:33 +08:00
parent 21057e56f2
commit 34d7c4a7a1
1 changed files with 1 additions and 0 deletions

View File

@ -33,6 +33,7 @@ def vc_fn(sid, input_audio, vc_transform, auto_f0,cluster_ratio, slice_db, noise
temp_path = "temp.wav"
soundfile.write(temp_path, audio, model.target_sample, format="wav")
_audio = model.slice_inference(temp_path, sid, vc_transform, slice_db, cluster_ratio, auto_f0, noise_scale,pad_seconds,cl_num,lg_num,lgr_num)
model.clear_empty()
os.remove(temp_path)
return "Success", (model.target_sample, _audio)
except Exception as e: