shyngys879's picture
Upload folder using huggingface_hub
c525e0d verified
Raw
History Blame Contribute Delete
552 Bytes
import os
import sys
import torch
MODEL_ID = "shyngys879/KazakhTTS-OmniVoice"
PORT = os.environ.get("PORT", "7860")
DEVICE = "cuda:0" if torch.cuda.is_available() else "cpu"
cmd = [
sys.executable,
"-m",
"omnivoice.cli.demo",
"--model",
MODEL_ID,
"--device",
DEVICE,
"--ip",
"0.0.0.0",
"--port",
str(PORT),
"--no-asr",
]
print("Starting KazakhTTS OmniVoice Space")
print("Model:", MODEL_ID)
print("Device:", DEVICE)
print("Port:", PORT)
print("Command:", " ".join(cmd))
os.execv(sys.executable, cmd)