Fix: style_by_dirs in WebUI
This commit is contained in:
@@ -79,9 +79,9 @@ powershell -c "irm https://astral.sh/uv/install.ps1 | iex"
|
|||||||
git clone https://github.com/litagin02/Style-Bert-VITS2.git
|
git clone https://github.com/litagin02/Style-Bert-VITS2.git
|
||||||
cd Style-Bert-VITS2
|
cd Style-Bert-VITS2
|
||||||
uv venv venv
|
uv venv venv
|
||||||
|
venv\Scripts\activate
|
||||||
uv pip install "torch<2.4" "torchaudio<2.4" --index-url https://download.pytorch.org/whl/cu118
|
uv pip install "torch<2.4" "torchaudio<2.4" --index-url https://download.pytorch.org/whl/cu118
|
||||||
uv pip install -r requirements.txt
|
uv pip install -r requirements.txt
|
||||||
venv\Scripts\activate
|
|
||||||
python initialize.py # 必要なモデルとデフォルトTTSモデルをダウンロード
|
python initialize.py # 必要なモデルとデフォルトTTSモデルをダウンロード
|
||||||
```
|
```
|
||||||
最後を忘れずに。
|
最後を忘れずに。
|
||||||
|
|||||||
@@ -336,7 +336,12 @@ def save_style_vectors_by_dirs(model_name: str, audio_dir_str: str):
|
|||||||
if style_vector_path.exists():
|
if style_vector_path.exists():
|
||||||
logger.info(f"Backup {style_vector_path} to {style_vector_path}.bak")
|
logger.info(f"Backup {style_vector_path} to {style_vector_path}.bak")
|
||||||
shutil.copy(style_vector_path, f"{style_vector_path}.bak")
|
shutil.copy(style_vector_path, f"{style_vector_path}.bak")
|
||||||
save_styles_by_dirs(audio_dir, result_dir)
|
save_styles_by_dirs(
|
||||||
|
wav_dir=audio_dir,
|
||||||
|
output_dir=result_dir,
|
||||||
|
config_path=config_path,
|
||||||
|
config_output_path=config_path,
|
||||||
|
)
|
||||||
return f"成功!\n{result_dir}にスタイルベクトルを保存しました。"
|
return f"成功!\n{result_dir}にスタイルベクトルを保存しました。"
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user