diff --git a/mockingbirdforuse/vocoder/wavernn/inference.py b/mockingbirdforuse/vocoder/wavernn/inference.py index c706f04..b39cab6 100644 --- a/mockingbirdforuse/vocoder/wavernn/inference.py +++ b/mockingbirdforuse/vocoder/wavernn/inference.py @@ -36,13 +36,7 @@ def __init__(self, model_path: Path): self._model.eval() def infer_waveform( - self, - mel, - normalize=True, - batched=True, - target=8000, - overlap=800, - progress_callback=None, + self, mel, normalize=True, batched=True, target=8000, overlap=800 ): """ Infers the waveform of a mel spectrogram output by the synthesizer (the format must match @@ -58,7 +52,5 @@ def infer_waveform( if normalize: mel = mel / hp.mel_max_abs_value mel = torch.from_numpy(mel[None, ...]) - wav = self._model.generate( - mel, batched, target, overlap, hp.mu_law, progress_callback - ) + wav = self._model.generate(mel, batched, target, overlap, hp.mu_law) return wav, hp.sample_rate diff --git a/mockingbirdforuse/vocoder/wavernn/models/fatchord_version.py b/mockingbirdforuse/vocoder/wavernn/models/fatchord_version.py index 63b21df..e20aa22 100644 --- a/mockingbirdforuse/vocoder/wavernn/models/fatchord_version.py +++ b/mockingbirdforuse/vocoder/wavernn/models/fatchord_version.py @@ -172,9 +172,8 @@ def forward(self, x, mels): x = F.relu(self.fc2(x)) return self.fc3(x) - def generate(self, mels, batched, target, overlap, mu_law, progress_callback=None): + def generate(self, mels, batched, target, overlap, mu_law): mu_law = mu_law if self.mode == "RAW" else False - progress_callback = progress_callback or self.gen_display self.eval() output = [] diff --git a/pyproject.toml b/pyproject.toml index 6c069d7..e6b725d 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "MockingBirdForUse" -version = "0.2.1" +version = "0.2.2" description = "" authors = ["meetwq "]