mirror of
https://github.com/ParisNeo/lollms.git
synced 2024-12-24 06:46:40 +00:00
Update lollms_xtts.py
This commit is contained in:
parent
5e7624c489
commit
33e00ead57
@ -172,6 +172,10 @@ class LollmsXTTS(LollmsTTS):
|
|||||||
return LollmsXTTS
|
return LollmsXTTS
|
||||||
|
|
||||||
def run_xtts_api_server(self):
|
def run_xtts_api_server(self):
|
||||||
|
root_dir = self.app.lollms_paths.personal_path
|
||||||
|
shared_folder = root_dir/"shared"
|
||||||
|
xtts_path = shared_folder / "xtts"
|
||||||
|
|
||||||
# Get the path to the current Python interpreter
|
# Get the path to the current Python interpreter
|
||||||
ASCIIColors.yellow("Loading XTTS ")
|
ASCIIColors.yellow("Loading XTTS ")
|
||||||
options= ""
|
options= ""
|
||||||
@ -179,7 +183,7 @@ class LollmsXTTS(LollmsTTS):
|
|||||||
options += " --deepspeed"
|
options += " --deepspeed"
|
||||||
if self.use_streaming_mode:
|
if self.use_streaming_mode:
|
||||||
options += " --streaming-mode --streaming-mode-improve --stream-play-sync"
|
options += " --streaming-mode --streaming-mode-improve --stream-play-sync"
|
||||||
process = run_python_script_in_env("xtts", f"-m xtts_api_server {options} -o {self.output_folder} -sf {self.voice_samples_path} -p {self.xtts_base_url.split(':')[-1].replace('/','')}", wait= False)
|
process = run_python_script_in_env("xtts", f"-m xtts_api_server {options} -o {self.output_folder} -sf {self.voice_samples_path} -p {self.xtts_base_url.split(':')[-1].replace('/','')}", cwd=xtts_path, wait= False)
|
||||||
return process
|
return process
|
||||||
|
|
||||||
def wait_for_service_in_another_thread(self, max_retries=150, show_warning=True):
|
def wait_for_service_in_another_thread(self, max_retries=150, show_warning=True):
|
||||||
|
Loading…
Reference in New Issue
Block a user