forked from IAHispano/Applio
-
Notifications
You must be signed in to change notification settings - Fork 9
Expand file tree
/
Copy pathgo-applio-manager.bat
More file actions
269 lines (229 loc) · 6.56 KB
/
go-applio-manager.bat
File metadata and controls
269 lines (229 loc) · 6.56 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
@echo off
title Applio Manager
:::
::: _ _
::: /\ | (_)
::: / \ _ __ _ __ | |_ ___
::: / /\ \ | '_ \| '_ \| | |/ _ \
::: / ____ \| |_) | |_) | | | (_) |
::: /_/ \_\ .__/| .__/|_|_|\___/
::: | | | |
::: |_| |_|
:::
:::
setlocal
set "branch=main"
set "runtime=runtime"
set "repoUrl=https://github.com/IAHispano/Applio-RVC-Fork.git"
set "fixesFolder=fixes"
set "localFixesPy=local_fixes.py"
set "principal=%cd%"
set "URL_BASE=https://huggingface.co/lj1995/VoiceConversionWebUI/resolve/main"
set "URL_EXTRA=https://huggingface.co/IAHispano/applio/resolve/main"
:menu
for /f "delims=: tokens=*" %%A in ('findstr /b ":::" "%~f0"') do @echo(%%A
echo [1] Reinstall Applio
echo [2] Update Applio
echo [3] Update Applio + Dependencies
echo.
set /p choice=Select an option:
set choice=%choice: =%
if "%choice%"=="1" (
cls
echo Starting Applio Reinstaller...
echo.
goto reinstaller
pause
cls
goto menu
)
if "%choice%"=="2" (
cls
echo Starting Applio Updater...
echo.
goto updater
pause
cls
goto menu
)
if "%choice%"=="3" (
cls
echo Updating Applio + Dependencies...
echo.
goto updaterDependencies
pause
cls
goto menu
)
cls
echo Invalid option. Please enter a number from 1 to 3.
echo.
echo Press 'Enter' to access the main menu...
pause>nul
cls
goto menu
:reinstaller
echo WARNING: Remember to install Microsoft C++ Build Tools, Redistributable, Python, and Git before continuing.
echo.
echo Step-by-step guide: https://rentry.org/appliolocal
echo Build Tools: https://aka.ms/vs/17/release/vs_BuildTools.exe
echo Redistributable: https://aka.ms/vs/17/release/vc_redist.x64.exe
echo Git: https://github.com/git-for-windows/git/releases/download/v2.42.0.windows.2/Git-2.42.0.2-64-bit.exe
echo Python: https://www.python.org/ftp/python/3.9.8/python-3.9.8-amd64.exe
echo.
pause
cls
echo %py_version% | findstr /C:"3.9.8" >nul
if %errorlevel% equ 0 (
echo Python 3.9.8 is installed, continuing...
) else (
echo Python 3.9.8 is not installed or not added to the path, exiting.
echo Press Enter to exit
pause
exit
)
echo Cloning the repository...
git pull
cd %repoFolder%
echo.
echo Proceeding to download the models...
echo.
echo WARNING: At this point, it's recommended to disable antivirus or firewall, as errors might occur when downloading pretrained models.
pause
cls
echo Downloading the "pretrained" folder...
cd "pretrained"
curl -LJO "%URL_BASE%/pretrained/D32k.pth"
curl -LJO "%URL_BASE%/pretrained/D40k.pth"
curl -LJO "%URL_BASE%/pretrained/D48k.pth"
curl -LJO "%URL_BASE%/pretrained/G32k.pth"
curl -LJO "%URL_BASE%/pretrained/G40k.pth"
curl -LJO "%URL_BASE%/pretrained/G48k.pth"
curl -LJO "%URL_BASE%/pretrained/f0D32k.pth"
curl -LJO "%URL_BASE%/pretrained/f0D40k.pth"
curl -LJO "%URL_BASE%/pretrained/f0D48k.pth"
curl -LJO "%URL_BASE%/pretrained/f0G32k.pth"
curl -LJO "%URL_BASE%/pretrained/f0G40k.pth"
curl -LJO "%URL_BASE%/pretrained/f0G48k.pth"
cd ".."
echo.
cls
echo Downloading the "pretrained_v2" folder...
cd "pretrained_v2"
curl -LJO "%URL_BASE%/pretrained_v2/D32k.pth"
curl -LJO "%URL_BASE%/pretrained_v2/D40k.pth"
curl -LJO "%URL_BASE%/pretrained_v2/D48k.pth"
curl -LJO "%URL_BASE%/pretrained_v2/G32k.pth"
curl -LJO "%URL_BASE%/pretrained_v2/G40k.pth"
curl -LJO "%URL_BASE%/pretrained_v2/G48k.pth"
curl -LJO "%URL_BASE%/pretrained_v2/f0D32k.pth"
curl -LJO "%URL_BASE%/pretrained_v2/f0D40k.pth"
curl -LJO "%URL_BASE%/pretrained_v2/f0D48k.pth"
curl -LJO "%URL_BASE%/pretrained_v2/f0G32k.pth"
curl -LJO "%URL_BASE%/pretrained_v2/f0G40k.pth"
curl -LJO "%URL_BASE%/pretrained_v2/f0G48k.pth"
cd ".."
echo.
cls
echo Downloading the "uvr5_weights" folder...
cd "uvr5_weights"
curl -LJO "%URL_BASE%/uvr5_weights/HP2_all_vocals.pth"
curl -LJO "%URL_BASE%/uvr5_weights/HP3_all_vocals.pth"
curl -LJO "%URL_BASE%/uvr5_weights/HP5_only_main_vocal.pth"
curl -LJO "%URL_BASE%/uvr5_weights/VR-DeEchoAggressive.pth"
curl -LJO "%URL_BASE%/uvr5_weights/VR-DeEchoDeReverb.pth"
curl -LJO "%URL_BASE%/uvr5_weights/VR-DeEchoNormal.pth"
cd ".."
echo.
cls
echo Downloading the rmvpe.pt file...
curl -LJO "%URL_BASE%/rmvpe.pt"
echo.
cls
echo Downloading the hubert_base.pt file...
curl -LJO "%URL_BASE%/hubert_base.pt"
echo.
cls
echo Downloading the ffmpeg.exe file...
curl -LJO "%URL_BASE%/ffmpeg.exe"
echo.
cls
echo Downloading the ffprobe.exe file...
curl -LJO "%URL_BASE%/ffprobe.exe"
echo.
cls
echo Downloading the runtime.zip file...
curl -LJO "%URL_EXTRA%/%runtime%.zip"
echo.
cls
echo Extracting the runtime.zip file, this might take a while...
powershell -Command "Expand-Archive -Path '%runtime%.zip' -DestinationPath '.'"
del %runtime%.zip
echo.
cls
echo Downloads completed!
echo.
echo Checking if the local_fixes.py file exists in the Fixes folder...
if exist "%fixesFolder%\%localFixesPy%" (
echo Running the file...
runtime\python.exe "%fixesFolder%\%localFixesPy%"
) else (
echo The "%localFixesPy%" file was not found in the "Fixes" folder.
)
echo.
echo Fixes Applied!
echo.
echo Applio has been reinstalled!
echo.
echo Press 'Enter' to access the main menu...
pause>nul
cls
goto menu
:updater
echo Updating the repo...
git pull
echo.
echo Verifying if the local_fixes.py file exists in the Fixes folder...
if exist "%fixesFolder%\%localFixesPy%" (
echo Running the file...
runtime\python.exe "%fixesFolder%\%localFixesPy%"
) else (
echo The file "%localFixesPy%" was not found in the "Fixes" folder.
)
echo.
echo Applio has been updated!
echo.
echo Press 'Enter' to access the main menu...
pause>nul
cls
goto menu
:updaterDependencies
echo Updating the repo...
git pull
echo.
echo Installing dependencies...
pip install -r requirements.txt
echo.
pip uninstall torch torchvision torchaudio -y
echo.
pip install torch==2.0.0 torchvision==0.15.1 torchaudio==2.0.1 --index-url https://download.pytorch.org/whl/cu117
echo.
pip install git+https://github.com/suno-ai/bark.git
echo.
cls
echo Dependencies installed!
echo.
echo Verifying if the local_fixes.py file exists in the Fixes folder...
if exist "%fixesFolder%\%localFixesPy%" (
echo Running the file...
runtime\python.exe "%fixesFolder%\%localFixesPy%"
) else (
echo The file "%localFixesPy%" was not found in the "Fixes" folder.
)
echo.
echo Applio has been updated!
echo.
echo Press 'Enter' to access the main menu...
pause>nul
cls
goto menu