Feat: use uv for bat installer

This commit is contained in:
litagin02
2024-05-29 06:53:21 +09:00
parent f4f94d4c20
commit 9625014184
4 changed files with 52 additions and 8 deletions

View File

@@ -395,7 +395,7 @@
"outputs": [], "outputs": [],
"source": [ "source": [
"# 日本語特化版を「使う」場合\n", "# 日本語特化版を「使う」場合\n",
"!python train_ms_jp_extra.py --config {config_path} --model {dataset_path} --assets_root {assets_root} --use_custom_batch_sampler" "!python train_ms_jp_extra.py --config {config_path} --model {dataset_path} --assets_root {assets_root}"
] ]
}, },
{ {
@@ -407,7 +407,7 @@
"outputs": [], "outputs": [],
"source": [ "source": [
"# 日本語特化版を「使わない」場合\n", "# 日本語特化版を「使わない」場合\n",
"!python train_ms.py --config {config_path} --model {dataset_path} --assets_root {assets_root} --use_custom_batch_sampler" "!python train_ms.py --config {config_path} --model {dataset_path} --assets_root {assets_root}"
] ]
}, },
{ {

22
requirements-infer.txt Normal file
View File

@@ -0,0 +1,22 @@
cmudict
cn2an
# faster-whisper==0.10.1
g2p_en
GPUtil
gradio
jieba
# librosa==0.9.2
loguru
num2words
# protobuf==4.25
psutil
# punctuators
# pyannote.audio>=3.1.0
# pyloudnorm
pyopenjtalk-dict
pypinyin
pyworld-prebuilt
# stable_ts
# tensorboard
transformers
# umap-learn

View File

@@ -89,6 +89,10 @@ if !errorlevel! neq 0 ( popd & exit /b !errorlevel! )
@REM Style-Bert-VITS2フォルダに移動 @REM Style-Bert-VITS2フォルダに移動
pushd Style-Bert-VITS2 pushd Style-Bert-VITS2
@REM 後で消す!!!!!!!!!!
git checkout dev
@REM 後で消す!!!!!!!!!!
echo -------------------------------------------------- echo --------------------------------------------------
echo Activating the virtual environment... echo Activating the virtual environment...
echo -------------------------------------------------- echo --------------------------------------------------
@@ -96,11 +100,18 @@ echo Executing: call ".\venv\Scripts\activate.bat"
call ".\venv\Scripts\activate.bat" call ".\venv\Scripts\activate.bat"
if !errorlevel! neq 0 ( popd & exit /b !errorlevel! ) if !errorlevel! neq 0 ( popd & exit /b !errorlevel! )
echo --------------------------------------------------
echo Installing package manager uv...
echo --------------------------------------------------
echo Executing: pip install uv
pip install uv
if !errorlevel! neq 0 ( pause & popd & exit /b !errorlevel! )
echo -------------------------------------------------- echo --------------------------------------------------
echo Installing dependencies... echo Installing dependencies...
echo -------------------------------------------------- echo --------------------------------------------------
echo Executing: pip install -r requirements.txt echo Executing: uv pip install -r requirements-infer.txt
pip install -r requirements.txt uv pip install -r requirements-infer.txt
if !errorlevel! neq 0 ( pause & popd & exit /b !errorlevel! ) if !errorlevel! neq 0 ( pause & popd & exit /b !errorlevel! )
echo ---------------------------------------- echo ----------------------------------------

View File

@@ -89,6 +89,10 @@ if !errorlevel! neq 0 ( popd & exit /b !errorlevel! )
@REM Style-Bert-VITS2フォルダに移動 @REM Style-Bert-VITS2フォルダに移動
pushd Style-Bert-VITS2 pushd Style-Bert-VITS2
@REM 後で消す!!!!!!!!!!
git checkout dev
@REM 後で消す!!!!!!!!!!
echo -------------------------------------------------- echo --------------------------------------------------
echo Activating the virtual environment... echo Activating the virtual environment...
echo -------------------------------------------------- echo --------------------------------------------------
@@ -96,18 +100,25 @@ echo Executing: call ".\venv\Scripts\activate.bat"
call ".\venv\Scripts\activate.bat" call ".\venv\Scripts\activate.bat"
if !errorlevel! neq 0 ( popd & exit /b !errorlevel! ) if !errorlevel! neq 0 ( popd & exit /b !errorlevel! )
echo --------------------------------------------------
echo Installing package manager uv...
echo --------------------------------------------------
echo Executing: pip install uv
pip install uv
if !errorlevel! neq 0 ( pause & popd & exit /b !errorlevel! )
echo -------------------------------------------------- echo --------------------------------------------------
echo Installing PyTorch... echo Installing PyTorch...
echo -------------------------------------------------- echo --------------------------------------------------
echo Executing: pip install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cu118 echo Executing: uv pip install torch torchaudio --index-url https://download.pytorch.org/whl/cu118
pip install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cu118 uv pip install torch torchaudio --index-url https://download.pytorch.org/whl/cu118
if !errorlevel! neq 0 ( pause & popd & exit /b !errorlevel! ) if !errorlevel! neq 0 ( pause & popd & exit /b !errorlevel! )
echo -------------------------------------------------- echo --------------------------------------------------
echo Installing other dependencies... echo Installing other dependencies...
echo -------------------------------------------------- echo --------------------------------------------------
echo Executing: pip install -r requirements.txt echo Executing: uv pip install -r requirements.txt
pip install -r requirements.txt uv pip install -r requirements.txt
if !errorlevel! neq 0 ( pause & popd & exit /b !errorlevel! ) if !errorlevel! neq 0 ( pause & popd & exit /b !errorlevel! )
echo ---------------------------------------- echo ----------------------------------------