SOTA Open Source TTS
Optimize firefly auto download
Lengyue2a7c88694090
diff --git a/fish_speech/models/vqgan/modules/firefly.py b/fish_speech/models/vqgan/modules/firefly.pyindex 7a3ddaa..52e448f 100644--- a/fish_speech/models/vqgan/modules/firefly.py+++ b/fish_speech/models/vqgan/modules/firefly.py@@ -502,9 +502,10 @@ class FireflyBase(nn.Module):if ckpt_path is not None:self.load_state_dict(torch.load(ckpt_path, map_location="cpu"))elif pretrained:- state_dict = torch.load(- "checkpoints/firefly-gan-base-generator.ckpt",+ state_dict = torch.hub.load_state_dict_from_url(+ "https://github.com/fishaudio/vocoder/releases/download/1.0.0/firefly-gan-base-generator.ckpt",map_location="cpu",+ model_dir="checkpoints",)if "state_dict" in state_dict: