Update TTS.py

fix bug
This commit is contained in:
tripleS-Dev 2025-07-18 00:51:41 +09:00 committed by GitHub
parent cefafee32c
commit 1e454f6d7f
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -306,7 +306,7 @@ class TTS_Config:
assert isinstance(configs, dict)
version = configs.get("version", "v2").lower()
assert version in ["v1", "v2", "v3", "v4", "v2pro", "v2proplus"]
self.default_configs[version] = configs.get(version, self.default_configs[version])
self.default_configs[version] = configs.get(version, self.default_configs.get(version, {}))
self.configs: dict = configs.get("custom", deepcopy(self.default_configs[version]))
self.device = self.configs.get("device", torch.device("cpu"))