From 8dfdbd6870a3d70d059be4b0594739cfd66db957 Mon Sep 17 00:00:00 2001 From: ggoknar Date: Mon, 30 Oct 2023 14:53:20 +0300 Subject: [PATCH] add some logs --- .github/workflows/build-and-push-to-ghcr.yml | 1 + server/main.py | 4 ++++ 2 files changed, 5 insertions(+) diff --git a/.github/workflows/build-and-push-to-ghcr.yml b/.github/workflows/build-and-push-to-ghcr.yml index abaf149..2ebb585 100644 --- a/.github/workflows/build-and-push-to-ghcr.yml +++ b/.github/workflows/build-and-push-to-ghcr.yml @@ -39,6 +39,7 @@ jobs: file: Dockerfile push: false cache-from: type=registry,ref=ghcr.io/coqui-ai/xtts-streaming-server:latest-cache + cache-to: type=registry,ref=ghcr.io/coqui-ai/xtts-streaming-server:latest-cache tags: coqui-ai/xtts-streaming-server:${{ env.RELEASE_VERSION }}-${{ github.sha }} #build-args: diff --git a/server/main.py b/server/main.py index 56bd94d..9f9cac8 100644 --- a/server/main.py +++ b/server/main.py @@ -22,14 +22,18 @@ device = torch.device("cuda") model_name = "tts_models/multilingual/multi-dataset/xtts_v1.1" +print("Downloading XTTS Model:",model_name) ModelManager().download_model(model_name) model_path = os.path.join(get_user_data_dir("tts"), model_name.replace("/", "--")) +print("XTTS Model downloaded") +print("Loading XTTS") config = XttsConfig() config.load_json(os.path.join(model_path, "config.json")) model = Xtts.init_from_config(config) model.load_checkpoint(config, checkpoint_dir=model_path, eval=True, use_deepspeed=True) model.to(device) +print("XTTS Loaded.") ##### Run fastapi ##### app = FastAPI(