Skip to content

Commit

Permalink
fix: remove possible leak in unused code
Browse files Browse the repository at this point in the history
  • Loading branch information
BlueAmulet committed Apr 1, 2023
1 parent 9c8df71 commit 9deb58b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/so_vits_svc_fork/inference/infer_tool.py
Original file line number Diff line number Diff line change
Expand Up @@ -485,7 +485,7 @@ def infer(
min_rms = 10 ** (db_thresh / 20)
if rms < min_rms:
LOG.info(f"Skip silence: RMS={rms:.2f} < {min_rms:.2f}")
return input_audio.copy()
return np.zeros_like(input_audio)
else:
LOG.info(f"Start inference: RMS={rms:.2f} >= {min_rms:.2f}")
infered_audio_c, _ = self.svc_model.infer(
Expand Down

0 comments on commit 9deb58b

Please sign in to comment.