Skip to content

SOTA Open Source TTS

Update firefly.py (#295)

cminus97e8e3c49104
diff --git a/fish_speech/models/vqgan/modules/firefly.py b/fish_speech/models/vqgan/modules/firefly.py
index 52e448f..4bfa7ca 100644
--- a/fish_speech/models/vqgan/modules/firefly.py
+++ b/fish_speech/models/vqgan/modules/firefly.py
@@ -500,7 +500,7 @@ class FireflyBase(nn.Module):
)
if ckpt_path is not None:
- self.load_state_dict(torch.load(ckpt_path, map_location="cpu"))
+ state_dict = torch.load(ckpt_path, map_location="cpu")
elif pretrained:
state_dict = torch.hub.load_state_dict_from_url(
"https://github.com/fishaudio/vocoder/releases/download/1.0.0/firefly-gan-base-generator.ckpt",