Merge pull request #5 from eginhard/fix-list-models

Fix TTS().list_models()
This commit is contained in:
Enno Hermann 2024-03-07 08:01:29 +01:00 committed by GitHub
commit f6464d7682
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 3 additions and 2 deletions

View File

@ -120,8 +120,9 @@ class TTS(nn.Module):
def get_models_file_path():
return Path(__file__).parent / ".models.json"
def list_models(self):
return ModelManager(models_file=TTS.get_models_file_path(), progress_bar=False, verbose=False)
@staticmethod
def list_models():
return ModelManager(models_file=TTS.get_models_file_path(), progress_bar=False, verbose=False).list_models()
def download_model_by_name(self, model_name: str):
model_path, config_path, model_item = self.manager.download_model(model_name)