Refactor: run "hatch run style:fmt"

This commit is contained in:
tsukumi
2024-09-17 05:25:29 +09:00
parent 7c5e839e82
commit a037b955ac
2 changed files with 8 additions and 3 deletions

View File

@@ -526,9 +526,10 @@ def create_inference_app(model_holder: TTSModelHolder) -> gr.Blocks:
if __name__ == "__main__":
from config import get_path_config
import torch
from config import get_path_config
path_config = get_path_config()
assets_root = path_config.assets_root
device = "cuda" if torch.cuda.is_available() else "cpu"

View File

@@ -204,7 +204,11 @@ if __name__ == "__main__":
if model_name:
# load_models() の 処理内容が i の正当性を担保していることに注意
model_ids = [i for i, x in enumerate(model_holder.models_info) if x.name == model_name]
model_ids = [
i
for i, x in enumerate(model_holder.models_info)
if x.name == model_name
]
if not model_ids:
raise_validation_error(
f"model_name={model_name} not found", "model_name"